/* The portfolio as a book on a table.
   Structure: .stage (the table) > .scene (perspective) > .book (3D) > .leaf (two .face sides + .flag bookmarks).
   Nothing between .scene and .face may set overflow, opacity or filter: any of them flattens the 3D
   and the pages stop stacking. Sizes inside a page are in em so a page scales as one piece.
   The look is Shalini's own: type, palette and the usability-test conceit come from her homepage concepts. */

:root {
  --table: #d7c0a0; --paper: #fbf6ec; --wall: #f6f1ea; --ink: #1a1917; --sub: #3a342e; --faint: #6a6058;
  --line: #d8ccbd; --dash: #bdb2a5; --chip: #eadfd0; --rust: #b5561a; --rust-text: #9c4614; --orange: #e8833a;
  --cloth: #1f2b45; --cream: #f4e6cf; --foil: #f2b27e;
  --accent: #b5561a; --accent-tint: #fffaf5;
  --sans: 'DM Sans', system-ui, sans-serif;
  --serif: 'Fraunces', Georgia, serif;
  --mono: 'JetBrains Mono', ui-monospace, monospace;
  --hand: 'Caveat', 'Segoe Print', cursive;
  --dur: 950ms; --ease: cubic-bezier(.62, .03, .24, 1);
  /* One landscape page. Height is the scarce dimension on laptops, so it wins. */
  /* 345px is the smallest page every spread still fits on; below that the screen scrolls. */
  --ph: max(345px, min(calc(100dvh - 304px), calc((100vw - 250px) / 2.6), 540px));
  --pw: calc(var(--ph) * 1.3);
  --grain: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='220' height='220'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .3 0 0 0 0 .18 0 0 0 0 .06 0 0 0 .55 -.08'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-font-smoothing: antialiased; }
body { font-family: var(--sans); color: var(--ink); background: var(--table); min-height: 100dvh; display: flex; flex-direction: column; position: relative; }
a { color: inherit; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
:focus-visible { outline: 2.5px solid var(--accent); outline-offset: 3px; border-radius: 4px; }
.skip { position: absolute; left: -999px; }
.skip:focus { left: 12px; top: 12px; background: #fff; padding: 8px 12px; z-index: 99; }
.task :focus-visible, .zone:focus-visible, .flag:focus-visible, .bar :focus-visible, .bar2 :focus-visible, .strip :focus-visible { outline-color: var(--ink); box-shadow: 0 0 0 6px rgba(255, 253, 246, .92); }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

/* ---------- top bar ---------- */
/* The bar is not a bar: her name and the links lie on the table itself, over the top of it. */
.top { position: absolute; left: 0; right: 0; top: 0; z-index: 5; height: var(--top, 62px); display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 0 clamp(16px, 3vw, 36px); }
.top :focus-visible { outline-color: var(--ink); box-shadow: 0 0 0 6px rgba(255, 253, 246, .92); }
.brand { font-family: var(--serif); font-size: 22px; text-decoration: none; white-space: nowrap; }
.toplinks { display: flex; align-items: center; gap: 2px; font-size: 14px; }
.toplinks > a, .toplinks > button { min-height: 40px; display: inline-flex; align-items: center; padding: 0 12px; border-radius: 999px; text-decoration: none; color: var(--sub); transition: background .2s, color .2s; }
.toplinks > a:hover, .toplinks > button:hover { background: rgba(255, 253, 246, .5); color: var(--ink); }
.toplinks .cta { border: 1.5px solid var(--ink); color: var(--ink); background: var(--paper); padding: 0 18px; margin-left: 8px; }
.toplinks .cta:hover { background: var(--ink); color: #fff; }
/* The music: a small puck speaker standing on the table by the top right corner, seen from above like everything
   else there. Dark cloth round the side, a ring of light under the top plate, and in the middle a rubber key sunk
   into the plate with play or pause moulded into it: the key is what you press. While there is sound the ring
   glows and beats in time, the body throbs with it and rings go out across the table. */
.toplinks > .speaker { position: relative; order: 9; flex: none; width: 58px; min-height: 0; margin-left: 14px; padding: 0; display: block; border-radius: 50%; background: none; color: var(--ink); } /* last in the top row, at the corner of the table: the open book can never cover it */
.top { overflow-x: clip; } /* its cord runs off the edge of the table, not off the page */
.toplinks > .speaker:hover { background: none; }
.speaker[hidden] { display: none !important; }
.speaker svg { display: block; width: 100%; overflow: visible; }
.speaker .body, .speaker .key { transform-box: fill-box; transform-origin: 50% 50%; }
.speaker .glow { stroke: #57524c; transition: stroke .3s; }
.speaker.on .glow { stroke: url(#spk-glow); filter: drop-shadow(0 0 2.2px rgba(96, 190, 255, .9)); }
.speaker .play, .speaker .pause { fill: #d9d4cb; stroke: #d9d4cb; filter: drop-shadow(0 .6px 0 rgba(0, 0, 0, .7)); transition: fill .2s, stroke .2s; } /* moulded: a hair of shadow under the symbol */
.speaker .pause { fill: none; display: none; } .speaker.on .play { display: none; } .speaker.on .pause { display: block; stroke: #bfeaff; }
.speaker .key { transition: transform .12s ease; } .speaker:hover .dome { filter: brightness(1.22); }
.speaker:active .key { transform: scale(.94); } .speaker:active .dome { filter: brightness(.82); } .speaker:active .rim { opacity: .08; } /* pressed: the key goes in */
.waves { position: absolute; left: 0; right: 0; top: 0; aspect-ratio: 1; pointer-events: none; }
.waves i { position: absolute; inset: 4%; border-radius: 50%; border: 1.5px solid rgba(58, 40, 20, .42); opacity: 0; }
.speaker.sounding .waves i { animation: ring 2.5s cubic-bezier(.2, .6, .4, 1) infinite; } .speaker.sounding .waves i:nth-child(2) { animation-delay: .833s; } .speaker.sounding .waves i:nth-child(3) { animation-delay: 1.666s; }
.speaker.sounding .body { animation: thump .833s cubic-bezier(.3, 0, .2, 1) infinite; } /* 72 beats a minute, the tempo of the music */
.speaker.sounding .glow { animation: beat .833s ease-out infinite; }
@keyframes ring { 0% { transform: scale(.96); opacity: 0; } 12% { opacity: .5; } 100% { transform: scale(1.62); opacity: 0; } }
@keyframes thump { 0%, 100% { transform: scale(1); } 12% { transform: scale(1.03); } 40% { transform: scale(1); } }
@keyframes beat { 0% { opacity: 1; stroke-width: 3.6; } 55%, 100% { opacity: .62; stroke-width: 2.8; } }
.listen { gap: 8px; padding: 0 12px 0 4px !important; border: 1.5px solid var(--ink); }
.listen[hidden] { display: none !important; }
.listen img { width: 28px; height: 28px; border-radius: 50%; object-fit: cover; object-position: center 22%; }
.listen[aria-pressed="true"] { background: var(--ink); color: #fff; }
.listen[aria-pressed="true"] img { box-shadow: 0 0 0 2px #fff, 0 0 0 4px var(--orange); animation: pulse 1.4s ease-in-out infinite; }
@keyframes pulse { 50% { box-shadow: 0 0 0 2px #fff, 0 0 0 7px transparent; } }

/* ---------- the table ---------- */
.stage {
  flex: 1; position: relative; isolation: isolate; overflow: clip; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px; padding: calc(var(--top, 62px) + 16px) 0 20px; /* her name and the links lie over the top of the table */
  background-color: var(--table);
  /* Light from the window, the room falling off at the edges, and the wood itself: growth rings and fibres, drawn
     by a filter (the level lines of a slow, stretched noise are the rings; that is why they loop and close). */
  background-image:
    radial-gradient(90% 70% at 22% 0%, rgba(255, 244, 224, .5), rgba(255, 244, 224, 0) 62%),
    radial-gradient(130% 120% at 50% 42%, rgba(74, 44, 16, 0) 52%, rgba(74, 44, 16, .3) 100%),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='1400' height='900'%3E%3Cfilter id='g' x='0' y='0' width='100%25' height='100%25' color-interpolation-filters='sRGB'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.0019 .0068' numOctaves='2' seed='23' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .37  0 0 0 0 .23  0 0 0 0 .11  1.7 0 0 0 -.35'/%3E%3CfeComponentTransfer result='rings'%3E%3CfeFuncA type='table' tableValues='0 0 0.09 0.26 0 0 0.10 0.27 0 0 0.12 0.33 0 0 0.10 0.29 0 0 0.07 0.19 0 0 0.12 0.35 0 0 0.11 0.32 0 0 0.11 0.31 0 0 0.08 0.22 0 0 0.08 0.22 0 0 0.14 0.41 0 0 0.11 0.32 0 0 0.09 0.25 0 0 0.07 0.20 0 0 0.10 0.30 0 0 0.15 0.43 0 0 0.09 0.27 0 0 0.06 0.17 0 0 0.10 0.28 0 0 0.12 0.33 0 0 0.14 0.39 0 0 0.06 0.18 0'/%3E%3C/feComponentTransfer%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.003 .42' numOctaves='2' seed='5' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .4  0 0 0 0 .25  0 0 0 0 .12  0 0 0 .62 -.2' result='fibre'/%3E%3CfeMerge%3E%3CfeMergeNode in='rings'/%3E%3CfeMergeNode in='fibre'/%3E%3C/feMerge%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url%28%23g%29'/%3E%3C/svg%3E");
  background-size: auto, auto, 1400px 900px;
}
/* afternoon light through a window with a plant in it */
.light { position: absolute; inset: 0; z-index: 0; pointer-events: none; overflow: hidden; }
.light i { position: absolute; left: -8%; top: -30%; width: 62%; height: 150%; transform: rotate(18deg); filter: blur(22px); opacity: .5;
  background: linear-gradient(90deg, rgba(255, 244, 222, 0) 0, rgba(255, 244, 222, .55) 12% 44%, rgba(255, 244, 222, 0) 47% 51%, rgba(255, 244, 222, .5) 54% 86%, rgba(255, 244, 222, 0) 100%); }
.light b { position: absolute; left: -6%; top: -12%; width: 58%; height: 86%; filter: blur(9px); opacity: .16; transform-origin: 0 0; animation: sway 13s ease-in-out infinite alternate;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 600 460'%3E%3Cg fill='%233a2208'%3E%3Cellipse cx='90' cy='70' rx='86' ry='26' transform='rotate(28 90 70)'/%3E%3Cellipse cx='210' cy='48' rx='74' ry='22' transform='rotate(-14 210 48)'/%3E%3Cellipse cx='168' cy='170' rx='92' ry='27' transform='rotate(41 168 170)'/%3E%3Cellipse cx='330' cy='120' rx='80' ry='23' transform='rotate(12 330 120)'/%3E%3Cellipse cx='70' cy='250' rx='78' ry='24' transform='rotate(62 70 250)'/%3E%3Cellipse cx='300' cy='260' rx='88' ry='25' transform='rotate(-22 300 260)'/%3E%3Cellipse cx='450' cy='70' rx='70' ry='20' transform='rotate(33 450 70)'/%3E%3Cellipse cx='430' cy='210' rx='64' ry='19' transform='rotate(58 430 210)'/%3E%3Cellipse cx='190' cy='350' rx='72' ry='21' transform='rotate(18 190 350)'/%3E%3Cpath d='M0 0C120 90 260 190 480 330' stroke='%233a2208' stroke-width='9' fill='none'/%3E%3C/g%3E%3C/svg%3E") 0 0 / 100% 100% no-repeat; }
@keyframes sway { from { transform: rotate(-1.2deg) translate(-6px, -4px); } to { transform: rotate(1.6deg) translate(12px, 8px); } }

/* cut-paper things on the table. .prop places and pushes; .in carries the entrance and the parallax. */
.room { position: absolute; inset: 0; z-index: -1; pointer-events: none; }
.prop { position: absolute; transition: transform var(--dur) var(--ease); }
.prop .in { display: block; transform: translate(calc(var(--mx, 0) * var(--depth, 6px)), calc(var(--my, 0) * var(--depth, 6px))); transition: transform .5s ease-out; }
.prop svg { display: block; overflow: visible; }
.lift { filter: drop-shadow(2px 3px 2.5px rgba(58, 32, 10, .4)); }
.lift2 { filter: drop-shadow(4px 7px 6px rgba(58, 32, 10, .36)); }
.grainy { position: absolute; inset: -60vh -50vw; background: var(--grain); opacity: .55; } .edge .grainy { inset: 0; }
.cup { right: calc(75% + 5.5vw); top: -7%; width: clamp(150px, 13.5vw, 210px); --depth: 9px; }
.scissors { right: calc(75% + 3vw); top: 64%; width: clamp(170px, 15vw, 240px); --depth: 5px; }
.scissors .in > svg { transform: rotate(-24deg); }
.glasses { left: calc(75% + 8.5vw); top: 5%; width: clamp(140px, 12vw, 190px); --depth: 7px; }
.glasses .in > svg { transform: rotate(9deg); }
/* the scissors snip twice now and then; a glint crosses the glasses */
.sc-a, .sc-b { transform-box: view-box; transform-origin: 120px 76px; } .sc-a { transform: rotate(-6deg); animation: snip-a 11s ease-in-out infinite; } .sc-b { transform: rotate(6deg); animation: snip-b 11s ease-in-out infinite; }
@keyframes snip-a { 0%, 85%, 91%, 100% { transform: rotate(-6deg); } 88%, 94% { transform: rotate(-.6deg); } }
@keyframes snip-b { 0%, 85%, 91%, 100% { transform: rotate(6deg); } 88%, 94% { transform: rotate(.6deg); } }
.glint { animation: glint 9s ease-in-out infinite; } @keyframes glint { 0%, 72% { transform: translateX(-74px); } 88%, 100% { transform: translateX(74px); } }
.scraps { right: calc(75% + 16vw); top: 88%; width: clamp(90px, 8vw, 130px); --depth: 4px; }
.room.edge { z-index: 0; } /* the two that live on the table's edge, whatever the book is doing */
.flowers { right: calc(-1 * clamp(18px, 2.4vw, 46px)); bottom: calc(-1 * clamp(36px, 4.6vw, 84px)); width: clamp(200px, 19vw, 330px); --depth: 12px; }
.cat { left: calc(-1 * clamp(14px, 1.8vw, 36px)); bottom: -16px; width: clamp(170px, 16vw, 280px); --depth: 10px; }
.stage:not(.is-closed) .cup, .stage:not(.is-closed) .scissors, .stage:not(.is-closed) .scraps { transform: translateX(calc(var(--pw) * -.5)); }
.stage:not(.is-closed) .glasses { transform: translateX(calc(var(--pw) * .5)); }
.steam { position: absolute; left: 22%; top: -8%; width: 46%; height: 60%; }
.steam svg { position: absolute; bottom: 0; width: 34%; opacity: 0; animation: steam 7s ease-in-out infinite; }
.steam svg:nth-child(1) { left: 4%; } .steam svg:nth-child(2) { left: 34%; animation-delay: -2.4s; } .steam svg:nth-child(3) { left: 62%; animation-delay: -4.7s; }
@keyframes steam { 0% { transform: translateY(26%) scale(.82) rotate(-3deg); opacity: 0; } 22% { opacity: .92; } 70% { opacity: .5; } 100% { transform: translateY(-34%) scale(1.08) rotate(7deg); opacity: 0; } }
.flowers .in, .cat .in, .cup .in { position: relative; } .flowers .in { aspect-ratio: 36 / 29; } .cat .in { aspect-ratio: 300 / 216; }
.prop .layer { position: absolute; inset: 0; width: 100%; height: 100%; }
.bloom { position: absolute; transform-origin: 50% 50%; animation: nod 7s ease-in-out infinite alternate; will-change: transform; }
.bloom.b1 { left: 4%; top: 2%; width: 50%; } .bloom.b2 { left: 44%; top: 30%; width: 34%; animation-duration: 9s; animation-delay: -3s; } .bloom.b3 { left: 13%; top: 52%; width: 27%; animation-duration: 8s; animation-delay: -5s; }
@keyframes nod { from { transform: rotate(-4deg); } to { transform: rotate(5deg); } }
.cat .breath { transform-origin: 50% 100%; animation: breathe 4.6s ease-in-out infinite alternate; will-change: transform; }
@keyframes breathe { from { transform: scale(1); } to { transform: scale(1.028, 1.04); } }
.cat .tail { transform-origin: 24% 78%; animation: wag 3.6s ease-in-out infinite alternate; will-change: transform; }
.cat .ears { transform-origin: 72% 46%; animation: twitch 7.5s ease-in-out infinite; will-change: transform; }
.sway { position: absolute; inset: 0; transform-origin: 98% 100%; animation: breeze 6.5s ease-in-out infinite alternate; will-change: transform; } /* the whole bouquet, from where the stems meet */
@keyframes wag { from { transform: rotate(-8deg); } to { transform: rotate(11deg); } }
@keyframes twitch { 0%, 86%, 100% { transform: none; } 89% { transform: scaleY(.82) rotate(-2.5deg); } 92% { transform: none; } 95% { transform: scaleY(.9) rotate(1.5deg); } }
@keyframes breeze { from { transform: rotate(-2deg); } to { transform: rotate(2.4deg); } }
.intro-anim .prop .in { animation: place 1.25s var(--ease) backwards; animation-delay: var(--wait, .2s); }
@keyframes place { from { transform: translate(var(--fx, 0), var(--fy, 0)) rotate(var(--fr, 0deg)); } }
.cup { --fx: -42vw; --fy: -8vh; --fr: -40deg; --wait: .15s; } .scissors { --fx: -40vw; --fy: 12vh; --fr: 30deg; --wait: .3s; }
.glasses { --fx: 40vw; --fy: -10vh; --fr: 25deg; --wait: .22s; } .scraps { --fx: -30vw; --fy: 30vh; --wait: .4s; }
.flowers { --fx: 30vw; --fy: 34vh; --fr: 20deg; --wait: .36s; } .cat { --fx: -26vw; --fy: 30vh; --wait: .5s; }

/* ---------- task line and scene ---------- */
.task { position: relative; z-index: 2; text-align: center; font-size: 14.5px; line-height: 1.4; min-height: 22px; padding: 0 16px; }
.task b { font-weight: 600; }
.scene { position: relative; width: calc(var(--pw) * 2); height: var(--ph); perspective: 2600px; perspective-origin: 50% 40%; }
.scene::after { /* the book's shadow on the table */
  content: ""; position: absolute; left: 3%; right: 1%; bottom: -30px; height: 56px; border-radius: 50%;
  background: radial-gradient(closest-side, rgba(52, 28, 8, .5), transparent); filter: blur(11px); z-index: -1;
  transition: transform var(--dur) var(--ease); transform: translateX(var(--shadow-x, 1%)) scaleX(var(--shadow-w, 1));
}
.book { position: absolute; inset: 0; transform-style: preserve-3d; transition: transform var(--dur) var(--ease); transform: translateX(var(--shift, 0)) rotateX(var(--tilt, 0deg)) rotateZ(var(--turn, 0deg)); }
.is-closed .book { --shift: -25%; --tilt: 9deg; --turn: -1.6deg; }
.is-closed .scene { --shadow-x: 1.5%; --shadow-w: .54; }
.leaf { position: absolute; top: 0; left: 50%; width: 50%; height: 100%; transform-origin: 0 50%; transform-style: preserve-3d; transition: transform var(--dur) var(--ease) var(--delay, 0ms); will-change: transform; }
.no-anim .leaf, .no-anim .book, .no-anim .scene::after, .no-anim .prop { transition: none !important; }

/* ---------- a page ---------- */
.face {
  position: absolute; inset: 0; backface-visibility: hidden; -webkit-backface-visibility: hidden; overflow: hidden;
  background: var(--paper) var(--grain); container-type: size; border-radius: 0 3px 3px 0;
  box-shadow: inset -1px 0 0 rgba(70, 50, 24, .2), inset 0 -1px 0 rgba(70, 50, 24, .14), inset 0 1px 0 rgba(70, 50, 24, .07);
}
.face.back { transform: rotateY(180deg); border-radius: 3px 0 0 3px; box-shadow: inset 1px 0 0 rgba(70, 50, 24, .2), inset 0 -1px 0 rgba(70, 50, 24, .14), inset 0 1px 0 rgba(70, 50, 24, .07); }
.face::before { /* the curve of the paper into the gutter */
  content: ""; position: absolute; inset: 0; pointer-events: none; z-index: 3;
  background: linear-gradient(90deg, rgba(60, 40, 20, .26), rgba(60, 40, 20, .08) 3.5%, rgba(60, 40, 20, 0) 13%, rgba(255, 255, 255, 0) 92%, rgba(255, 255, 255, .45) 100%);
}
.face.back::before { transform: scaleX(-1); }
.face:focus { outline: none; }
.face::after { content: ""; position: absolute; inset: 0; pointer-events: none; z-index: 4; background: #1a1408; opacity: 0; }
.leaf.turning .face::after { animation: shade var(--dur) var(--ease) var(--delay, 0ms); }
@keyframes shade { 45% { opacity: .24; } }
.pg { position: absolute; inset: 0; padding: 7.2cqh 6.6cqw 8.6cqh; display: flex; flex-direction: column; font-size: clamp(11px, 2.5cqw, 18px); line-height: 1.5; } /* the type grows with the page all the way up, so a big screen shows a full page, not a small one with wide margins */
.run { display: flex; justify-content: space-between; align-items: center; gap: 1em; font-family: var(--mono); font-size: max(.66em, 9px); letter-spacing: .14em; text-transform: uppercase; color: var(--faint); margin-bottom: 1.5em; }
.folio { position: absolute; bottom: 3.4cqh; left: 0; right: 0; text-align: center; font-family: var(--mono); font-size: max(.68em, 9px); color: var(--faint); letter-spacing: .1em; }
h1, h2, h3 { font-family: var(--serif); font-weight: 400; letter-spacing: -.012em; line-height: 1.08; text-wrap: balance; }
.grow { flex: 1; min-height: 0; }
.btn { display: inline-flex; align-items: center; gap: .5em; padding: .62em 1.1em; border-radius: 999px; font-weight: 500; font-size: .92em; text-decoration: none; border: 1.5px solid var(--ink); background: #fff; transition: transform .2s, box-shadow .2s; white-space: nowrap; }
.btn:hover { transform: translate(-1px, -2px); box-shadow: 3px 4px 0 var(--ink); }
.btn.solid { background: var(--ink); color: #fff; }
.btn.solid:hover { box-shadow: 3px 4px 0 var(--c, var(--rust)); }
.btn .arr { transition: transform .2s; } .btn:hover .arr { transform: translateX(3px); }
.acts { display: flex; flex-wrap: wrap; gap: .6em; align-items: center; }
.pill { display: inline-flex; align-items: center; gap: .45em; min-height: 24px; padding: .28em .7em .28em .55em; border-radius: 999px; font-size: .78em; font-weight: 500; color: var(--c); background: var(--t); border: var(--b, 1px solid); border-color: var(--bc, transparent); white-space: nowrap; }
button.pill:hover { box-shadow: 0 0 0 2px var(--t), 0 0 0 3.5px var(--c); }
.edge { position: absolute; inset: 2.3cqh 2.1cqw; pointer-events: none; opacity: .78; } .edge svg { display: block; width: 100%; height: 100%; overflow: visible; }
.pill::before { content: ""; width: .5em; height: .5em; border-radius: 50%; background: var(--c); }
.pill.plain { color: var(--sub); background: var(--chip); } .pill.plain::before { display: none; }
.pill.kind { background: rgba(255, 253, 246, .5); border-color: var(--c); --t: var(--paper); padding-left: .7em; } .pill.kind::before { display: none; } /* a kind of work: outlined in its own line, where an industry is filled */
.pills { display: flex; flex-wrap: wrap; gap: .4em; }
/* a page corner, folded: the way to turn */
.ear { position: absolute; bottom: 0; right: 0; width: var(--ear, 0em); height: var(--ear, 0em); z-index: 5; pointer-events: none; transition: width .3s var(--ease), height .3s var(--ease);
  background: linear-gradient(to bottom right, #fffdf6 0, #e6dbc6 49%, rgba(70, 50, 24, .3) 50%, #efe6d3 54%, #f4ecdc 100%); box-shadow: -2px -2px 5px rgba(70, 50, 24, .16); border-radius: .2em 0 0 0; }
.back .ear { right: auto; left: 0; transform: scaleX(-1); }
.leaf.is-right .front .ear, .leaf.is-left .back .ear { --ear: 1.25em; }
.peek-next .leaf.is-right .front .ear, .peek-prev .leaf.is-left .back .ear { --ear: 2.7em; }
.hard .ear { display: none; }

/* ---------- cover and endpapers ---------- */
.leaf.hard .face { inset: -.55em -.7em -.55em 0; border-radius: 0 .5em .5em 0; box-shadow: none; }
.leaf.hard .face.back { inset: -.55em 0 -.55em -.7em; border-radius: .5em 0 0 .5em; }
.face.cover, .outside, .endpaper { background-color: var(--cloth); color: var(--cream); background-image: var(--grain), radial-gradient(120% 100% at 34% 0%, #2c3b60, var(--cloth) 66%); }
/* Quarter-bound: a cloth spine wraps the back, and the boards are covered in paper. The board has an edge. */
.leaf.hard .face.cover { cursor: pointer; border-radius: .3em .5em .5em .3em; box-shadow: inset 0 1.5px 0 rgba(255, 255, 255, .17), inset -2px -2px 0 rgba(0, 0, 0, .42); }
.face.cover::before { background: linear-gradient(112deg, rgba(255, 255, 255, .08), rgba(255, 255, 255, 0) 38%, rgba(0, 0, 0, .17)); } /* light across the board */
.spine { position: absolute; left: 0; top: 0; bottom: 0; width: 8.4cqw; z-index: 2; pointer-events: none; border-radius: .3em 0 0 .3em; background-color: #6e2a1e;
  /* left to right: the rounded back, the shoulder catching light, the groove the board hinges in, then flat cloth */
  background-image: linear-gradient(90deg, rgba(0, 0, 0, .52) 0, rgba(0, 0, 0, .16) 13%, rgba(255, 255, 255, .15) 33%, rgba(255, 255, 255, .04) 47%, rgba(0, 0, 0, .34) 59%, rgba(0, 0, 0, .55) 64.5%, rgba(255, 255, 255, .2) 69.5%, rgba(0, 0, 0, 0) 82%),
    repeating-linear-gradient(0deg, rgba(255, 255, 255, .055) 0 1px, transparent 1px 2.5px), repeating-linear-gradient(90deg, rgba(0, 0, 0, .15) 0 1px, transparent 1px 2.5px);
  box-shadow: 2px 0 3px rgba(0, 0, 0, .4), inset -1px 0 0 rgba(242, 178, 126, .6), inset 0 1.5px 0 rgba(255, 255, 255, .14), inset 0 -2px 0 rgba(0, 0, 0, .4); }
.c-clip { position: absolute; inset: 0 0 0 8.4cqw; overflow: hidden; border-radius: 0 .5em .5em 0; }
/* The picture stands inside the cover with room all round it: the finished card on top, the board it came from below. */
.c-board { position: absolute; right: 5.2%; top: 6.5%; height: 87%; aspect-ratio: 300 / 430; }
.c-board svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.c-board .made { animation: afloat 7s ease-in-out infinite alternate; will-change: transform; } /* the card rides a little above the board */
@keyframes afloat { from { transform: translateY(-.5%); } to { transform: translateY(.9%); } }
.note, .spark { transform-box: fill-box; transform-origin: 50% 50%; }
.spark { animation: twinkle 3.4s ease-in-out infinite; animation-delay: var(--w, 0ms); }
@keyframes twinkle { 0%, 100% { opacity: .4; transform: scale(.45); } 50% { opacity: 1; transform: scale(.72); } }
.threads path { stroke-dasharray: 1; }
/* when the cover comes into view: the notes go up one by one, the threads are drawn, and the card is set down last */
.gather .note { animation: pin-up .5s cubic-bezier(.2, 1.5, .4, 1) backwards; animation-delay: var(--w, 0ms); }
@keyframes pin-up { from { transform: translateY(-9px) scale(.45); } } /* a stalled animation leaves small notes, never a blank cover */
.gather .threads path { animation: thread 1s ease-out backwards; animation-delay: var(--w, 0ms); }
@keyframes thread { from { stroke-dashoffset: 1; } }
.gather .drop { animation: set-down .8s 1.3s cubic-bezier(.2, .9, .25, 1) backwards; }
@keyframes set-down { from { transform: translate(0, -46px) rotate(-7deg); } }
.stage:not(.is-closed) .c-clip * { animation-play-state: paused; }
.cover .pg { padding: 11.5cqh 49cqw 10.5cqh 14cqw; }
.c-text { display: flex; flex-direction: column; flex: 1; min-width: 0; min-height: 0; }
.kicker { font-family: var(--mono); font-size: max(.66em, 9px); letter-spacing: .2em; text-transform: uppercase; color: rgba(244, 230, 207, .82); }
.cover h1 { font-size: 2.6em; line-height: 1.03; letter-spacing: -.02em; margin-top: .85em; }
.cover h1 em { display: inline-block; font-style: italic; color: var(--foil); position: relative; }
.cover h1 em::after { content: ""; position: absolute; left: -.04em; right: -.06em; bottom: -.1em; height: .2em;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 14' preserveAspectRatio='none'%3E%3Cpath d='M2 8C18 2 30 12 46 6S76 3 98 8' fill='none' stroke='%23F2B27E' stroke-width='2.2' stroke-linecap='round'/%3E%3C/svg%3E") center / 100% 100% no-repeat; }
.cover .sub { font-family: var(--serif); font-style: italic; font-size: 1.12em; line-height: 1.28; margin-top: .9em; color: rgba(244, 230, 207, .92); max-width: 12.5em; }
.cover .rule { display: block; width: 2.9em; height: 1px; background: rgba(244, 230, 207, .6); margin-top: auto; }
.cover .by { font-family: var(--serif); font-size: 1.5em; margin-top: .65em; }
.cover .role { font-family: var(--mono); font-size: max(.66em, 9px); letter-spacing: .12em; line-height: 1.7; text-transform: uppercase; color: rgba(244, 230, 207, .82); margin-top: .6em; }
@container (max-aspect-ratio: 1/1) { /* a portrait cover, on a phone: the picture sits above the title */
  .c-board { left: 0; right: 0; top: 3.5%; height: 45%; aspect-ratio: auto; } /* the whole picture, smaller, above the title */
  .cover .pg { padding: 51cqh 8cqw 5.5cqh 17cqw; }
  .cover h1 { font-size: 2.4em; margin-top: .45em; } .cover .sub { max-width: none; margin-top: .6em; } .cover .rule { margin-top: 1em; }
}
/* inside the boards: the cloth shows as a rim round the pasted-down paper */
.endpaper .pg { inset: .55em 0 .55em .7em; background: #f3ead9 var(--grain); color: var(--ink); border-radius: .15em;
  background-image: radial-gradient(rgba(58, 52, 46, .2) .055em, transparent .07em), var(--grain); background-size: 1.15em 1.15em, auto; }
.front.endpaper .pg { inset: .55em .7em .55em 0; }
.card { background: #fff; border: 1.5px solid var(--ink); border-radius: .9em; box-shadow: .45em .45em 0 var(--ink); padding: 1.4em 1.5em 1.5em; max-width: 25em; margin: auto; transform: rotate(-1.4deg); }
.card h2 { font-size: 1.62em; margin: .55em 0 .7em; }
.card ol { list-style: none; display: grid; gap: .7em; counter-reset: n; border-top: 1px dashed var(--dash); padding-top: .9em; }
.card li { display: grid; grid-template-columns: 2em 1fr; gap: .3em; counter-increment: n; font-size: .93em; color: var(--sub); }
.card li::before { content: "0" counter(n); font-family: var(--mono); font-size: .8em; color: var(--rust-text); padding-top: .2em; }
.card b { font-weight: 600; color: var(--ink); }

/* ---------- front matter ---------- */
.run img { width: 3.6em; height: 3.6em; border-radius: 50%; object-fit: cover; object-position: center 22%; border: 1.5px solid var(--ink); margin: -1.2em 0; }
.intro h2 { font-size: 2.2em; margin-bottom: .45em; }
.intro p { color: #2d2a27; font-size: .95em; line-height: 1.5; } .intro p + p { margin-top: .55em; }
.intro .strength { font-family: var(--serif); font-style: italic; font-size: 1.3em; line-height: 1.36; margin: .5em 0 .45em; text-wrap: balance; }
.intro .strength span { padding: .04em .16em; border-radius: .25em .5em .3em .45em; background: linear-gradient(100deg, transparent .6%, #f8e9a6 2.6% 97%, transparent 99.4%); -webkit-box-decoration-break: clone; box-decoration-break: clone; }
.intro .three button { font-weight: 600; border-bottom: 1.5px solid var(--rust); } .intro .three button:hover { color: var(--rust-text); }
@container (min-aspect-ratio: 1/1) { .intro .acts, .intro .grow { display: none; } } /* a landscape page has no room for them: both are in the top bar */
.sign { font-family: var(--hand); font-size: 1.9em !important; line-height: 1 !important; color: var(--sub) !important; margin-top: .3em !important; }
.toc h2, .idx h2, .abt h2 { font-size: 2em; }
.pg.toc, .pg.idx { padding-top: 5.6cqh; }
.tochead { display: flex; justify-content: space-between; align-items: baseline; gap: 1em; } .tochead .run { margin: 0; }
/* what's inside: one line a chapter. Its industries are named in their colours, so nobody has to learn what a dot means. */
.toc ol { list-style: none; display: grid; margin-top: .3em; }
.toc .sec { display: flex; align-items: center; gap: .9em; font-family: var(--mono); font-size: max(.58em, 8.5px); letter-spacing: .16em; text-transform: uppercase; color: var(--faint); margin: .62em 0 .1em; }
.toc .sec::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.toc button { display: flex; align-items: baseline; gap: .55em; width: 100%; text-align: left; padding: 0 .35em; margin-left: -.35em; border-radius: .35em; font-size: .84em; line-height: 1.46; transition: background .2s; }
.toc button:hover { background: rgba(255, 253, 246, .7); } .toc button:hover .t { color: var(--rust-text); }
.toc .n { font-family: var(--mono); font-size: max(.74em, 9px); color: var(--rust-text); width: 1.6em; flex: none; }
.toc .t { font-family: var(--serif); font-size: 1.12em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; transition: color .2s; }
.toc .epi .t { font-style: italic; }
.toc .dots { flex: 1; border-bottom: 1.5px dotted #a89a88; transform: translateY(-.25em); min-width: .8em; }
.toc .tags { display: flex; gap: .7em; flex: none; } .toc .tags i { display: inline-flex; align-items: center; gap: .32em; font-style: normal; font-size: .82em; font-weight: 500; color: var(--c); white-space: nowrap; }
.toc .tags i::before { content: ""; width: .5em; height: .5em; border-radius: 50%; background: var(--c); }
.toc .p { font-family: var(--mono); font-size: .76em; color: var(--sub); width: 1.9em; text-align: right; flex: none; }
/* the three she names in her introduction carry a small hand-drawn star, explained once at the foot of the page */
.toc .first .t::after, .starred span { content: ""; display: inline-block; width: .8em; height: .8em; margin-left: .4em; vertical-align: -.04em;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2.500l2.300 6.300 6.700.400-5.200 4.200 1.800 6.500-5.600-3.700-5.600 3.700 1.800-6.500-5.200-4.200 6.700-.400Z' fill='%23e8833a' stroke='%239c4614' stroke-width='1.600' stroke-linejoin='round'/%3E%3C/svg%3E") center / contain no-repeat; }
.toc .first .t { overflow: visible; }
.starred { font-family: var(--hand); font-size: 1.3em; line-height: 1; color: var(--sub); white-space: nowrap; transform: rotate(-2deg); } .starred span { margin: 0 .4em 0 0; width: .7em; height: .7em; }
/* the index: each kind of work is a thread through the twelve chapters, in that kind's own colour and line */
.idx .lede { color: var(--sub); font-size: .88em; margin: .3em 0 .7em; max-width: 34em; }
.thr { display: grid; grid-template-columns: minmax(10.4em, 37%) 1fr; align-items: center; gap: .7em; min-height: 2.25em; }
.kind-of { display: flex; align-items: center; gap: .5em; min-width: 0; } .kind-of .pill { font-size: .74em; min-height: 22px; }
.kind-of > span { font-family: var(--mono); font-size: max(.62em, 8.5px); color: var(--faint); }
.run-of { position: relative; display: grid; grid-template-columns: repeat(12, 1fr); align-items: center; justify-items: center; height: 2.1em; }
.run-of::before { content: ""; position: absolute; left: 4.17%; right: 4.17%; top: 50%; height: 1px; background: var(--line); }
.run-of svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; grid-column: 1 / -1; }
.run-of path { fill: none; stroke: var(--c); stroke-width: 1.5; stroke-linecap: round; stroke-dasharray: 4 3.5; vector-effect: non-scaling-stroke; opacity: .8; }
.run-of i { position: relative; width: 3px; height: 3px; border-radius: 50%; background: #b9ad9c; }
.bead { position: relative; width: 1.5em; height: 1.9em; min-width: 20px; display: grid; place-items: center; }
.bead::before { content: ""; width: .7em; height: .7em; min-width: 8px; min-height: 8px; border-radius: 50%; background: var(--c); box-shadow: 0 0 0 2.5px var(--paper); transition: transform .2s; }
.bead:hover::before, .bead:focus-visible::before { transform: scale(1.45); }
/* the name of the chapter, shown while the pointer or the keyboard is on its bead or its number */
.bead::after, .nums button::after { content: attr(data-name); position: absolute; left: 50%; bottom: calc(100% - .15em); transform: translateX(-50%); padding: .22em .6em; border-radius: .4em; background: var(--ink); color: #fff; font-family: var(--sans); font-size: max(.7em, 10px); letter-spacing: 0; text-transform: none; white-space: nowrap; opacity: 0; pointer-events: none; transition: opacity .15s; z-index: 3; }
.bead:hover::after, .bead:focus-visible::after, .nums button:hover::after, .nums button:focus-visible::after { opacity: 1; }
.run-of > :nth-last-child(-n+4)::after { left: auto; right: -.2em; transform: none; } /* near the edge of the page the name opens leftwards */
.thr.head { min-height: 0; margin-bottom: .1em; } .thr.head .kind-of span { letter-spacing: .14em; text-transform: uppercase; }
.nums { height: 1.5em; } .nums::before { display: none; }
.nums button { position: relative; font-family: var(--mono); font-size: max(.62em, 8.5px); color: var(--rust-text); min-width: 1.6em; padding: .2em 0; } .nums button:hover { color: var(--ink); }
.tipline { font-size: .84em; color: var(--faint); margin-top: auto; padding-top: .8em; }

/* ---------- a chapter ---------- */
.pg.ch { padding-top: 6.2cqh; } .ch .run { margin-bottom: .9em; } .ch .run span { white-space: nowrap; }
.ch h2 { font-size: 2.3em; margin-top: .3em; white-space: nowrap; }
.ch.long h2 { font-size: 1.85em; }
.ch .meta { font-family: var(--mono); font-size: max(.68em, 9px); letter-spacing: .08em; text-transform: uppercase; color: var(--faint); margin-top: .62em; }
/* the synopsis: one line in the book's own type that says what the work was, running into who it was for and why */
.brief { margin-top: .7em; color: var(--sub); font-size: .96em; line-height: 1.46; max-width: 38em; text-wrap: pretty; }
.brief b { font-family: var(--serif); font-weight: 500; font-size: 1.14em; letter-spacing: -.005em; color: var(--ink); }
.lab { font-family: var(--mono); font-size: max(.64em, 9px); letter-spacing: .08em; text-transform: uppercase; color: var(--faint); margin-bottom: .55em; }
/* Notebook blocks. What she saw and what she changed are two paper notes taped to the page with an arrow from one
   to the other; the result is stamped and run over with a highlighter; a number worth remembering is ringed by hand. */
.notes { position: relative; display: grid; grid-template-columns: 1fr 1fr; gap: 1.7em; margin-top: 1em; font-size: .93em; line-height: 1.36; list-style: none; }
.notes > div { position: relative; padding: .75em .9em .7em; background: #f8e9a6; box-shadow: 2px 6px 9px -5px rgba(58, 32, 10, .5); transform: rotate(-1.3deg); }
.notes > div + div { background: var(--t, #e6edf7); transform: rotate(1.1deg); }
.notes > div::before { content: ""; position: absolute; top: -.6em; left: 50%; width: 3.6em; height: 1.1em; transform: translateX(-50%) rotate(-3deg); background: rgba(255, 253, 246, .72); box-shadow: 0 1px 2px rgba(58, 32, 10, .22); } /* a strip of tape */
.notes > div + div::before { transform: translateX(-50%) rotate(4deg); }
.notes::after { content: ""; position: absolute; left: 50%; top: 46%; width: 2.7em; height: 1.5em; transform: translate(-50%, -50%); z-index: 1;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 60 32'%3E%3Cg fill='none' stroke='%231a1917' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 22C18 7 36 6 53 15'/%3E%3Cpath d='M44 6l10 9-12 4'/%3E%3C/g%3E%3C/svg%3E") center / contain no-repeat; }
.notes dt { font-family: var(--hand); font-size: 1.42em; line-height: 1; color: var(--sub); margin-bottom: .26em; }
/* a job with no case study: what she worked on there, pinned up a note each; and where there is room, the chapter's number, large and quiet */
.numeral { position: absolute; right: 6.6cqw; bottom: 8.6cqh; font-family: var(--serif); font-style: italic; font-weight: 300; font-size: 6em; line-height: .8; letter-spacing: -.04em; color: var(--chip); pointer-events: none; }
.notes.worked { margin-top: 1.3em; gap: 1.15em 1.3em; } .notes.worked.n3 { grid-template-columns: repeat(3, 1fr); gap: 1em; } .notes.worked::after { display: none; }
.worked li { position: relative; padding: .8em .85em .75em; background: #f8e9a6; box-shadow: 2px 6px 9px -5px rgba(58, 32, 10, .5); transform: rotate(-1.2deg); }
.worked li:nth-child(2) { background: var(--t, #e6edf7); transform: rotate(1deg); } .worked li:nth-child(3) { background: #fffdf6; transform: rotate(.6deg); } .worked li:nth-child(4) { background: #f6d9c4; transform: rotate(-.8deg); }
.worked li::before { content: ""; position: absolute; top: -.55em; left: 50%; width: 3.2em; height: 1em; transform: translateX(-50%) rotate(-3deg); background: rgba(255, 253, 246, .72); box-shadow: 0 1px 2px rgba(58, 32, 10, .22); }
.worked li:nth-child(even)::before { transform: translateX(-50%) rotate(4deg); }
.worked b { display: block; font-family: var(--hand); font-weight: 600; font-size: 1.5em; line-height: 1.02; color: var(--ink); } .worked span { display: block; margin-top: .3em; color: var(--sub); }
.result, .proof { margin-top: auto; padding-top: .55em; }
.result { display: flex; align-items: center; gap: 1em; }
.result .lab, .proof .lab { display: inline-block; flex: none; margin: 0; padding: .32em .7em .26em; border: 1.5px solid var(--c, var(--rust-text)); border-radius: .3em; color: var(--c, var(--rust-text)); letter-spacing: .16em; transform: rotate(-2.5deg); } /* a rubber stamp */
.result b { font-family: var(--serif); font-weight: 400; font-size: 1.36em; line-height: 1.4; padding: .06em .22em; border-radius: .25em .5em .3em .45em; text-wrap: balance;
  background: linear-gradient(100deg, transparent .6%, var(--t, #f8e9a6) 2.6% 97%, transparent 99.4%); -webkit-box-decoration-break: clone; box-decoration-break: clone; } /* highlighter, a little uneven at the ends */
.proof { display: flex; align-items: center; gap: 1.1em; }
.proof b { position: relative; font-family: var(--serif); font-weight: 400; font-size: 2.1em; letter-spacing: -.02em; color: var(--c); white-space: nowrap; padding: .05em .3em; }
.proof b::after { content: ""; position: absolute; inset: -.1em -.14em; border: 2px solid var(--c); border-radius: 52% 46% 55% 48% / 58% 46% 56% 44%; transform: rotate(-3deg); opacity: .85; } /* ringed by hand */
.proof span { color: var(--sub); font-size: .9em; }
/* her browser frame: every picture is a recording being watched */
.shot { flex: 1; min-height: 0; margin: 0 .6em .6em 0; display: flex; flex-direction: column; position: relative; border: 1.5px solid var(--ink); border-radius: .85em; overflow: hidden; background: #fff; box-shadow: .55em .55em 0 var(--ink); }
.chrome { display: flex; align-items: center; gap: .55em; padding: .6em .9em; border-bottom: 1.5px solid var(--ink); font-family: var(--mono); font-size: max(.66em, 9px); color: var(--sub); white-space: nowrap; overflow: hidden; }
.chrome i { width: .8em; height: .8em; border-radius: 50%; border: 1.5px solid var(--ink); flex: none; }
.chrome span { margin-left: .3em; overflow: hidden; text-overflow: ellipsis; }
.view { flex: 1; min-height: 0; display: flex; justify-content: center; align-items: flex-start; gap: 3%; position: relative; overflow: hidden; }
.shot.screen .view { padding: 6% 6% 0; } .shot.screen img { width: 100%; border-radius: .4em .4em 0 0; box-shadow: 0 .6em 2em rgba(0, 0, 0, .22); }
.shot.fill .view img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: left top; }
.shot.art .view img { position: absolute; inset: 4% 0 0; width: 100%; height: 96%; object-fit: contain; background: none; }
.shot.phones .view { padding: 5% 8% 0; } .shot.phones img { width: 29%; border-radius: .9em .9em 0 0; box-shadow: 0 .6em 2em rgba(0, 0, 0, .18); }
.shot.wide .view { justify-content: flex-start; padding: 5% 0 0 6%; } .shot.wide img { width: 150%; max-width: none; border-radius: .5em 0 0 0; }
.view img { display: block; background: #fff; }
a.view { cursor: zoom-in; text-decoration: none; color: inherit; }
/* the bottom corner of a picture that unfolds: it lifts when you come near, and says what it does */
.peel { position: absolute; right: 0; bottom: 0; width: 2.6em; height: 2.6em; transition: width .3s var(--ease), height .3s var(--ease);
  background: linear-gradient(to top left, var(--paper) 0 49%, rgba(40, 24, 8, .36) 50%, #e9dfcb 55%, #fbf6ec 100%); border-radius: .5em 0 0 0; box-shadow: -3px -3px 6px rgba(40, 24, 8, .24); }
.peel b { position: absolute; right: calc(100% + .5em); bottom: .5em; padding: .4em .8em; border-radius: .5em; background: var(--ink); color: #fff; font-family: var(--mono); font-weight: 500; font-size: max(.6em, 9px); letter-spacing: .08em; text-transform: uppercase; white-space: nowrap; opacity: 0; transition: opacity .2s; }
a.view:hover .peel, a.view:focus-visible .peel { width: 4.6em; height: 4.6em; } a.view:hover .peel b, a.view:focus-visible .peel b { opacity: 1; transition-delay: .1s; }
.leaf.is-right a.view .peel { animation: beckon 7s ease-in-out 2.5s infinite; } @keyframes beckon { 0%, 82%, 100% { width: 2.6em; height: 2.6em; } 88%, 93% { width: 3.7em; height: 3.7em; } }
.voice { display: block; position: absolute; left: .8em; bottom: .8em; max-width: 64%; padding: .7em .9em; border-radius: .9em .9em .9em .15em; background: #fff; border: 1.5px solid var(--ink); font-size: .86em; line-height: 1.38; }
.voice span { display: block; margin-bottom: .35em; font-family: var(--mono); font-size: .76em; color: var(--faint); }
.under { display: flex; justify-content: space-between; align-items: center; gap: .8em; margin-top: .9em; flex-wrap: wrap; }
.also { display: block; margin-top: .45em; padding: .3em 0; min-height: 24px; font-size: .84em; color: var(--sub); text-decoration: none; }
.also b { font-weight: 500; color: var(--ink); border-bottom: 1.5px solid var(--ink); } .also:hover b { color: var(--rust); border-color: var(--rust); }
.quote { flex: 1; min-height: 0; margin: 0 .6em .6em 0; border: 1.5px solid var(--ink); border-radius: .85em; box-shadow: .55em .55em 0 var(--ink); background: var(--t); padding: 1.6em 1.7em; display: flex; flex-direction: column; justify-content: center; }
.quote { position: relative; } .quote::before { content: ""; position: absolute; top: -.6em; left: 12%; width: 4.4em; height: 1.2em; transform: rotate(-4deg); background: rgba(232, 178, 60, .82); box-shadow: 0 1px 2px rgba(58, 32, 10, .25); }
.quote .lab { color: var(--c); margin-bottom: 1em; }
.asks { margin-top: 1.05em; } .asks .lab { margin-bottom: .5em; }
.pill.ask { text-decoration: none; min-height: 30px; padding: .34em .85em; white-space: normal; } .pill.ask::before { display: none; } .pill.ask:hover { box-shadow: 0 0 0 2px var(--t), 0 0 0 3.5px var(--c); }
.quote p { font-family: var(--serif); font-size: 1.5em; line-height: 1.24; letter-spacing: -.01em; }
.note { font-size: .84em; color: var(--faint); max-width: 21em; }

/* ---------- back matter ---------- */
.abt .lede { color: var(--sub); font-size: .95em; margin: .8em 0 1em; max-width: 30em; }
.log { list-style: none; border-top: 1.5px solid var(--ink); }
.log li { display: grid; grid-template-columns: 3.4em 8.6em 1fr; gap: .2em .9em; align-items: baseline; padding: .72em 0; border-bottom: 1px solid var(--line); }
.log .at { font-family: var(--mono); font-size: max(.78em, 9px); color: var(--rust-text); } .log b { font-family: var(--serif); font-weight: 400; font-size: 1.42em; line-height: 1.1; } .log p { font-size: .9em; color: var(--sub); line-height: 1.45; }
.more { align-self: flex-start; margin-top: 1em; font-size: .93em; text-decoration: none; padding-bottom: .25em; border-bottom: 1.5px solid var(--ink); } .more:hover { color: var(--rust); border-color: var(--rust); }
.rows { display: grid; gap: .4em; margin-top: .5em; }
.rows > div { display: flex; justify-content: space-between; gap: 1em; align-items: baseline; padding-bottom: .4em; border-bottom: 1px solid var(--line); }
.rows b { font-weight: 600; font-size: .95em; display: block; } .rows span { font-size: .84em; color: var(--sub); } .rows i { font-style: normal; font-family: var(--mono); font-size: .72em; color: var(--faint); white-space: nowrap; }
.lab2 { font-family: var(--mono); font-size: max(.64em, 9px); letter-spacing: .08em; text-transform: uppercase; color: var(--faint); margin: 1.05em 0 .5em; }
.lab2:first-child { margin-top: 0; }
.lab2 .ic { width: 1.5em; height: 1.5em; vertical-align: -.42em; margin-right: .45em; color: var(--rust-text); }
/* her facts page carries the most: everything on it is set a size smaller than elsewhere in the book */
.abt .pills { gap: .3em; } .abt .pill { font-size: .72em; min-height: 0; padding: .2em .62em; }
.abt .rows { gap: .25em; margin-top: .3em; } .abt .rows > div { padding-bottom: .25em; } .abt .lab2 { margin: .68em 0 .34em; } .abt .trio span { line-height: 1.3; }
.deg { display: flex; align-items: flex-start; gap: .6em; } .deg .ic { flex: none; width: 1.35em; height: 1.35em; margin-top: .1em; color: var(--rust-text); }
.duo { display: grid; grid-template-columns: minmax(0, 3.4fr) minmax(0, 1fr); gap: 0 1.4em; margin-top: .8em; }
.trio { display: grid; grid-template-columns: repeat(3, 1fr); gap: .8em; } .trio b { font-weight: 600; display: block; font-size: .93em; } .trio span { font-size: .78em; color: var(--sub); line-height: 1.36; display: block; margin-top: .1em; }
/* away from work, each on its own paper: a recipe card, a sheet cut from coloured paper, a page from a notebook */
.away { position: relative; padding: .52em .65em .55em; border-radius: .3em; box-shadow: 1px 3px 6px -3px rgba(58, 32, 10, .45); }
.away .ic { position: absolute; top: .5em; right: .5em; width: 1.45em; height: 1.45em; }
.away b { padding-right: 1.7em; }
.away.cooking { background: linear-gradient(#b8432a 0 .24em, transparent .24em), repeating-linear-gradient(transparent 0 1.06em, rgba(150, 90, 30, .16) 1.06em calc(1.06em + 1px)) 0 1.8em, #fbefd2; transform: rotate(-1deg); }
.away.cooking b, .away.cooking .ic { color: #8a3a1c; }
.away.crafts { background: #fbe3ea; border: 1.5px dashed #c45a80; transform: rotate(.9deg); }
.away.crafts b, .away.crafts .ic { color: #9c2f5a; } .away.crafts .ic { fill: rgba(196, 90, 128, .18); }
.away.poems { padding-left: 1.55em; background: linear-gradient(90deg, transparent 1.05em, rgba(196, 70, 60, .5) 1.05em calc(1.05em + 1px), transparent 0), repeating-linear-gradient(transparent 0 1.1em, rgba(31, 43, 69, .16) 1.1em calc(1.1em + 1px)) 0 .4em, #fffdf6; transform: rotate(-.6deg); }
.away.poems b, .away.poems .ic { color: #1f2b45; } .away.poems span { font-family: var(--hand); font-size: 1.02em; line-height: 1.1; color: #2c3a5c; } .away.poems a { color: inherit; }
/* the last page: her post-task questionnaire, on dark paper */
/* ---------- the last spread: goodbye, and a note to her pasted inside the back cover ---------- */
.epi-head { display: flex; align-items: center; gap: 1.1em; margin-top: .3em; }
.epi-head img { width: 5.2em; height: 5.2em; flex: none; border-radius: 50%; object-fit: cover; object-position: center 22%; border: 1.5px solid var(--ink); box-shadow: .28em .28em 0 var(--ink); }
.epi h2 { font-size: 2.2em; line-height: 1.05; } .epi .by { font-family: var(--mono); font-size: max(.66em, 9px); letter-spacing: .1em; text-transform: uppercase; color: var(--faint); margin-top: .7em; }
.epi-text { margin-top: 1.05em; font-family: var(--serif); font-size: 1.16em; line-height: 1.4; max-width: 27em; text-wrap: pretty; }
.reach { display: flex; flex-wrap: wrap; gap: .5em 2.4em; margin-top: 1em; }
.reach dt { font-family: var(--mono); font-size: max(.62em, 9px); letter-spacing: .12em; text-transform: uppercase; color: var(--faint); } .reach dd { font-size: .98em; margin-top: .15em; }
.reach a { text-decoration: none; border-bottom: 1.5px solid var(--ink); } .reach a:hover { color: var(--rust-text); border-color: var(--rust-text); }
.elsewhere { margin-top: auto; padding-top: .9em; } .elsewhere .lab { margin-bottom: .6em; }
.icons { display: flex; flex-wrap: wrap; gap: .6em; --mark: var(--ink); } /* her places as marks only: one colour, so they read as a set */
.ico { display: grid; place-items: center; width: 2.9em; height: 2.9em; min-width: 44px; min-height: 44px; border-radius: 50%; border: 1.5px solid var(--ink); background: #fffdf6; transition: transform .2s, box-shadow .2s; }
.ico svg { width: 46%; height: 46%; overflow: visible; } .ico:hover { transform: translate(-1px, -2px); box-shadow: 3px 4px 0 var(--ink); }
.imprint { margin-top: .75em; font-family: var(--mono); font-size: max(.6em, 8.5px); letter-spacing: .12em; text-transform: uppercase; color: var(--faint); }
/* the note: a sheet from a pad, taped down a little askew, in her handwriting where it is hers and the reader's where it is theirs */
.letter { position: relative; width: 86%; margin: auto; padding: 1.5em 1.6em 1.3em; background: #fffdf6 var(--grain); box-shadow: 0 1px 0 rgba(58, 32, 10, .14), .2em .7em 1.1em -.5em rgba(40, 24, 8, .6); transform: rotate(-1.8deg); display: flex; flex-direction: column; gap: .5em; }
.letter .tape { position: absolute; top: -.6em; left: 9%; width: 4.2em; height: 1.2em; transform: rotate(-5deg); background: rgba(232, 178, 60, .8); box-shadow: 0 1px 2px rgba(58, 32, 10, .25); }
.letter .tape + .tape { left: auto; right: 9%; transform: rotate(4deg); }
.letter .hi { font-family: var(--hand); font-weight: 600; font-size: 2.1em; line-height: 1; color: var(--ink); }
.letter .quiet { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.letter textarea, .letter input { display: block; width: 100%; border: 0; border-radius: 0; background: transparent; color: var(--ink); font-family: var(--hand); font-size: 1.5em; }
.letter textarea { --row: 1.36em; height: calc(var(--row) * 4); line-height: var(--row); resize: none; padding: 0; background: repeating-linear-gradient(transparent 0 calc(var(--row) - 1.5px), rgba(31, 43, 69, .22) calc(var(--row) - 1.5px) calc(var(--row) - .5px), transparent calc(var(--row) - .5px) var(--row)) local; }
.signed { display: grid; grid-template-columns: 1fr 1fr; gap: 0 1.4em; margin-top: .3em; }
.signed span { display: block; font-family: var(--mono); font-size: max(.6em, 9px); letter-spacing: .12em; text-transform: uppercase; color: var(--faint); }
.signed input { padding: .05em 0 .1em; min-height: 1.6em; border-bottom: 1.5px solid rgba(31, 43, 69, .45); } .signed input::placeholder, .letter textarea::placeholder { color: #8a7f72; opacity: 1; }
.letter :focus-visible { outline: 2px solid var(--rust); outline-offset: 3px; }
.trap { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; } /* the field only bots fill in */
.letter.is-sending .btn { opacity: .6; cursor: progress; }
/* once it has gone: a postmark stamped across the corner, and the note can no longer be changed */
.posted { position: absolute; right: 7%; bottom: 13%; padding: .2em .7em; border: 2.5px solid var(--rust); border-radius: .3em; font-family: var(--mono); font-weight: 500; font-size: 1.3em; letter-spacing: .28em; text-transform: uppercase; color: var(--rust); opacity: 0; transform: rotate(-12deg) scale(1.6); pointer-events: none; }
.letter.is-sent .posted { opacity: .88; transform: rotate(-12deg) scale(1); transition: transform .32s cubic-bezier(.3, 1.6, .5, 1), opacity .12s; }
.letter.is-sent .btn { display: none; }
.post { display: flex; align-items: center; gap: .9em; flex-wrap: wrap; margin-top: .7em; } .said { flex: 1; min-width: 9em; font-size: .86em; color: var(--sub); }

/* ---------- bookmarks ---------- */
.flag { position: absolute; left: calc(100% - 1.5em); top: calc(6.5% + var(--row) * var(--step, 11.2%)); width: 6.6em; height: 9.4%; min-height: 26px; transform-style: preserve-3d; transform: translateZ(-.3px); transition: transform .28s var(--ease); font-size: clamp(11px, calc(var(--ph) * .031), 14.5px); }
.flag:hover, .flag:focus-visible { transform: translateZ(-.3px) translateX(.55em); }
.flag span { position: absolute; inset: 0; backface-visibility: hidden; -webkit-backface-visibility: hidden; display: flex; align-items: center; justify-content: flex-end; padding: 0 .7em; font-weight: 600; font-size: .86em; letter-spacing: .01em; color: var(--c); background: var(--t); border: var(--b, 1px solid); border-color: var(--c); border-left: 0; border-radius: 0 .5em .5em 0; box-shadow: 1px 2px 3px rgba(58, 32, 10, .3); }
.flag span + span { transform: rotateY(180deg); justify-content: flex-start; border: var(--b, 1px solid); border-color: var(--c); border-right: 0; border-radius: .5em 0 0 .5em; }
.flag.on span { background: var(--c); color: #fff; }
.intro-anim .flag { animation: flagin .7s var(--ease) backwards; animation-delay: calc(.7s + var(--row) * 70ms); }
@keyframes flagin { from { transform: translateZ(-.3px) translateX(-5.4em); } }
.intro-anim .scene { animation: rise 1s var(--ease) backwards; }
@keyframes rise { from { transform: translateY(26px) scale(.98); } } /* no opacity: a stalled animation must not hide the book */

/* ---------- turning by the page edge ---------- */
/* Kept inside the page margin so the strips never sit on a button or a bookmark. The folded corner is the cue. */
.zone { position: absolute; top: 0; bottom: 0; width: 3%; z-index: 5; }
.zone.prev { left: 0; cursor: w-resize; } .zone.next { right: 0; cursor: e-resize; }
.is-closed .zone { display: none; } /* a closed book opens by its cover */

/* ---------- the thread under the book ---------- */
.bar, .bar2, .strip { position: relative; z-index: 2; }
.bar { display: flex; align-items: flex-start; gap: 10px; width: min(calc(var(--pw) * 2 + 80px), calc(100vw - 32px)); } /* as wide as the open book, so the longest chapter name fits beside each arrow */
.step { flex: 1 1 0; min-width: 0; min-height: 44px; display: flex; align-items: center; gap: 8px; font-size: 14.5px; text-align: left; border-radius: 8px; transition: opacity .2s; }
.step.prev { justify-content: flex-end; text-align: right; }
.step .to { min-width: 0; font-family: var(--serif); font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.step .arr { flex: none; width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; border: 1.5px solid var(--ink); background: var(--paper); transition: transform .2s, box-shadow .2s; }
.step:hover:not([aria-disabled="true"]) .arr { transform: translate(-1px, -2px); box-shadow: 2px 3px 0 var(--ink); }
.step[aria-disabled="true"] { opacity: .32; cursor: default; }
.line { position: relative; flex: 0 1 calc(var(--pw) * .88); min-width: 0; height: 62px; }
.line::before { content: ""; position: absolute; left: 14px; right: 14px; top: 21px; height: 2px; border-radius: 2px; background: var(--ink); opacity: .82; }
.beads { position: absolute; left: 14px; right: 14px; top: 0; height: 44px; pointer-events: none; }
.beads svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.beads path { fill: none; stroke: var(--accent); stroke-width: 2.2; stroke-linecap: round; stroke-dasharray: 7 5; vector-effect: non-scaling-stroke; animation: sew .9s var(--ease) backwards; }
@keyframes sew { from { stroke-dashoffset: 90; opacity: 0; } }
.beads i { position: absolute; top: 22px; left: calc(var(--at) * 100%); width: 9px; height: 9px; margin: -4.5px 0 0 -4.5px; border-radius: 50%; background: var(--paper); border: 1.5px solid var(--ink); transition: background .3s, transform .3s, opacity .3s; }
.beads i.minor { width: 6px; height: 6px; margin: -3px 0 0 -3px; background: var(--ink); }
.beads i.first { width: 9px; height: 12px; margin: -6px 0 0 -4.5px; border-radius: 1px 3px 3px 1px; background: var(--cloth); border-color: var(--cloth); }
.beads i.read { background: var(--ink); }
.beads i.in { background: var(--accent); border-color: var(--accent); transform: scale(1.35); }
.has-thread .beads i:not(.in):not(.minor):not(.first) { opacity: .45; }
#scrub { position: absolute; left: 0; top: 0; width: 100%; height: 44px; margin: 0; background: none; -webkit-appearance: none; appearance: none; cursor: grab; }
#scrub:active { cursor: grabbing; }
#scrub::-webkit-slider-runnable-track { height: 44px; background: none; }
#scrub::-moz-range-track { height: 44px; background: none; }
#scrub::-webkit-slider-thumb { -webkit-appearance: none; width: 28px; height: 28px; margin-top: 8px; border: 0; border-radius: 50%; background: radial-gradient(circle, var(--accent) 0 5px, var(--paper) 5.6px 9.6px, var(--ink) 10.2px 11.8px, transparent 12.4px); filter: drop-shadow(1px 2px 1.5px rgba(58, 32, 10, .45)); transition: transform .2s; }
#scrub::-moz-range-thumb { width: 28px; height: 28px; border: 0; border-radius: 50%; background: radial-gradient(circle, var(--accent) 0 5px, var(--paper) 5.6px 9.6px, var(--ink) 10.2px 11.8px, transparent 12.4px); filter: drop-shadow(1px 2px 1.5px rgba(58, 32, 10, .45)); }
#scrub:hover::-webkit-slider-thumb, #scrub:active::-webkit-slider-thumb { transform: scale(1.14); }
#scrub:focus-visible { outline: 2.5px solid var(--ink); outline-offset: 0; border-radius: 22px; box-shadow: 0 0 0 5px rgba(255, 253, 246, .92); }
.where { position: absolute; left: 0; right: 0; top: 40px; text-align: center; font-size: 13.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; pointer-events: none; }
.where b { font-family: var(--serif); font-weight: 400; font-size: 15.5px; } .where.peeking { font-style: italic; }
.bar2 { display: flex; align-items: center; justify-content: center; gap: 10px 12px; flex-wrap: wrap; padding: 0 16px; min-height: 44px; }
.toggle { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; padding: 0 22px; border-radius: 999px; background: var(--ink); color: #fff; font-weight: 500; font-size: 15px; transition: transform .2s, box-shadow .2s; }
.toggle:hover { transform: translate(-1px, -2px); box-shadow: 3px 4px 0 rgba(58, 32, 10, .55); }
.aside { font-family: var(--mono); font-size: 12px; color: var(--ink); }
.stage:not(.is-closed) .aside { display: none; }
.thread { display: none; align-items: center; gap: 8px; font-size: 14px; background: var(--accent-tint); color: var(--accent); border: 1.5px solid var(--accent); border-radius: 999px; padding: 3px 4px 3px 14px; font-weight: 500; }
.has-thread .thread { display: inline-flex; }
.thread .x { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; }
.thread .x:hover { background: rgba(255, 255, 255, .75); }
.onward { display: none; font-size: 14px; font-weight: 500; background: var(--accent); color: #fff; border-radius: 999px; padding: 0 18px; min-height: 44px; align-items: center; text-decoration: none; }
.has-thread .onward { display: inline-flex; gap: 8px; }
.strip { display: none; }
.for-touch { display: none; }
/* ---------- the fold-out: a case study unfolds over the book ----------
   A sheet folded in four. .q-a is the quarter the rest folds onto, .fold-l the flap beside it (folded over it, the
   picture on its back), .fold-b the lower half (folded underneath). reader.js says where the open sheet lies
   (--x --y --w --h) and where the folded packet starts (--from: on the picture).
   Open, the sheet lies flat and .flat, the copy the reader uses, covers the parts. Nothing is drawn across the
   page (fold lines sat still while the words scrolled under them, which looked wrong); a paperclip on the top edge
   is what says this is a loose sheet. */
.reader { position: fixed; inset: 0; z-index: 60; visibility: hidden; pointer-events: none; } /* laid out even while hidden, so the page is printed before it is needed */
.reader.on { visibility: visible; pointer-events: auto; }
.reader-dim { position: absolute; inset: 0; background: rgba(40, 24, 8, .5); opacity: 0; transition: opacity .5s ease; cursor: zoom-out; }
.reader.is-open > .reader-dim { opacity: 1; }
.reader.is-closing > .reader-dim { transition-delay: 1s; }
.sheet { position: absolute; left: 0; top: 0; width: var(--w, 1100px); height: var(--h, 700px); transform-origin: 0 0; transform: translate(var(--x, 0px), var(--y, 0px)); perspective: 2600px; outline: none; }
.q-a, .fold-l, .fold-b, .flat { position: absolute; }
.q-a { left: 0; top: 0; width: calc(50% + .5px); height: calc(50% + .5px); overflow: hidden; background: #fff; border-radius: 4px 0 0 0; box-shadow: 0 16px 36px -14px rgba(40, 24, 8, .6); }
.fold-l { left: 50%; top: 0; width: 50%; height: calc(50% + .5px); transform-origin: 0 50%; transform-style: preserve-3d; transform: rotateY(-179.6deg); }
.fold-b { left: 0; top: 50%; width: 100%; height: 50%; transform-origin: 50% 0; transform-style: preserve-3d; transform: rotateX(-179.6deg); visibility: hidden; }
.fold-l > i, .fold-b > i { position: absolute; inset: 0; font-style: normal; overflow: hidden; background: #fff; backface-visibility: hidden; -webkit-backface-visibility: hidden; }
.fold-l > .in { border-radius: 0 4px 0 0; box-shadow: 0 16px 36px -14px rgba(40, 24, 8, .6); }
.fold-l > .out { transform: rotateY(180deg); border-radius: 4px 0 0 0; background-size: cover; background-position: left top; background-repeat: no-repeat; } /* its back: the picture the packet lifts off */
.fold-b > .in { border-radius: 0 0 4px 4px; box-shadow: 0 26px 46px -16px rgba(40, 24, 8, .62); }
.fold-b > .out { transform: rotateX(180deg); background: var(--paper) var(--grain); }
/* the page, laid out at the size of the whole sheet and cut to each part */
.pane { position: absolute; left: 0; top: 0; width: var(--w, 1100px); height: var(--h, 700px); background: #fff; }
.fold-l .pane { left: calc(var(--w, 1100px) * -.5); } .fold-b .pane { top: calc(var(--h, 700px) * -.5); }
.pane iframe, .flat iframe { display: block; width: 100%; height: 100%; border: 0; background: #fff; }
/* the copy the reader uses: it takes over the moment the last part lands, and gives way the moment folding starts */
.flat { inset: 0; z-index: 2; visibility: hidden; overflow: hidden; border-radius: 4px; background: #fff; }
/* a part that is turning away from the light goes dark, and brightens as it comes down */
.fold-l > i::before, .fold-b > i::before { content: ""; position: absolute; inset: 0; z-index: 2; pointer-events: none; background: #20130a; opacity: 0; }
/* a paperclip slides onto the top edge once the sheet is flat */
.clip { position: absolute; left: 6.5%; top: -23px; width: 30px; height: 78px; z-index: 4; pointer-events: none; overflow: visible; transform: translateY(-16px) rotate(-7deg); opacity: 0; filter: drop-shadow(1.5px 2.5px 1.5px rgba(40, 24, 8, .38)); transition: transform .12s ease, opacity .1s ease; }
.reader.is-open .clip { transform: rotate(-7deg); opacity: 1; transition: transform .38s cubic-bezier(.2, 1.3, .4, 1) 1.98s, opacity .16s ease 1.98s; }
/* two paper tabs stand up from the top edge once the sheet is open */
.tabs { position: absolute; bottom: 100%; right: 18px; display: flex; gap: 6px; transform: translateY(100%); opacity: 0; transition: transform .2s ease, opacity .15s ease; z-index: 3; }
.reader.is-open .tabs { transform: none; opacity: 1; transition: transform .45s var(--ease) 1.75s, opacity .3s ease 1.75s; }
.tab { display: inline-flex; align-items: center; min-height: 40px; padding: 0 16px; border-radius: 9px 9px 0 0; font-size: 14px; font-weight: 500; text-decoration: none; border: 1.5px solid var(--ink); border-bottom: 0; background: var(--paper); color: var(--ink); box-shadow: 0 -3px 8px -4px rgba(40, 24, 8, .4); }
.tab.fold-back { background: var(--ink); color: #fff; }
.tab:hover { transform: translateY(-2px); } .tab:focus-visible { outline-color: #fff; box-shadow: 0 0 0 5px var(--ink); }
.reading { overflow: hidden; }

/* unfolding: the packet rises off the picture; the flap is lifted, falls open, lands and settles; then the lower half */
.reader.is-open .sheet { animation: sheet-rise .5s cubic-bezier(.2, .75, .25, 1) both; }
.reader.is-open .fold-l { animation: open-l .86s .34s both; }
.reader.is-open .fold-b { animation: open-b .9s 1.02s both, appear 0s 1.02s both; }
.reader.is-open .fold-l > .out::before { animation: darken .86s .34s both; }
.reader.is-open .fold-l > .in::before { animation: brighten .86s .34s both; }
.reader.is-open .fold-b > .in::before { animation: brighten .9s 1.02s both; }
.reader.is-open .flat { animation: appear 0s 1.95s both; }
@keyframes sheet-rise { from { transform: var(--from); } to { transform: translate(var(--x), var(--y)); } }
@keyframes open-l {
  0% { transform: rotateY(-179.6deg); animation-timing-function: cubic-bezier(.45, .05, .55, .95); }
  44% { transform: rotateY(-96deg); animation-timing-function: cubic-bezier(.55, .05, .9, .6); }
  76% { transform: rotateY(-1deg); animation-timing-function: cubic-bezier(.15, .6, .4, 1); }
  88% { transform: rotateY(-5deg); animation-timing-function: cubic-bezier(.5, 0, .7, .6); }
  100% { transform: rotateY(0deg); }
}
@keyframes open-b {
  0% { transform: rotateX(-179.6deg); animation-timing-function: cubic-bezier(.45, .05, .55, .95); }
  42% { transform: rotateX(-96deg); animation-timing-function: cubic-bezier(.55, .05, .9, .6); }
  76% { transform: rotateX(-1deg); animation-timing-function: cubic-bezier(.15, .6, .4, 1); }
  88% { transform: rotateX(-4.5deg); animation-timing-function: cubic-bezier(.5, 0, .7, .6); }
  100% { transform: rotateX(0deg); }
}
@keyframes darken { 0% { opacity: 0; } 46%, 100% { opacity: .42; } }
@keyframes brighten { 0%, 44% { opacity: .4; } 80%, 100% { opacity: 0; } }
@keyframes appear { from { visibility: hidden; } to { visibility: visible; } }
/* folding back: the lower half swings under, the flap is lifted and laid back over, and the packet drops onto the picture */
.reader.is-closing .fold-b { animation: close-b .62s .04s cubic-bezier(.5, 0, .35, 1) both, vanish 0s .66s both; }
.reader.is-closing .fold-l { animation: close-l .68s .56s both; }
.reader.is-closing .fold-l > .in::before { animation: brighten .68s .56s reverse both; }
.reader.is-closing .fold-l > .out::before { animation: darken .68s .56s reverse both; }
.reader.is-closing .sheet { animation: sheet-drop .42s 1.2s cubic-bezier(.5, 0, .8, .45) both; }
@keyframes close-b { from { transform: rotateX(0deg); } to { transform: rotateX(-179.6deg); } }
@keyframes close-l {
  0% { transform: rotateY(0deg); animation-timing-function: cubic-bezier(.45, .05, .55, .95); }
  46% { transform: rotateY(-90deg); animation-timing-function: cubic-bezier(.55, .05, .9, .6); }
  86% { transform: rotateY(-178deg); animation-timing-function: cubic-bezier(.15, .6, .4, 1); }
  93% { transform: rotateY(-173deg); animation-timing-function: cubic-bezier(.5, 0, .7, .6); }
  100% { transform: rotateY(-179.6deg); }
}
@keyframes vanish { from { visibility: visible; } to { visibility: hidden; } }
@keyframes sheet-drop { from { transform: translate(var(--x), var(--y)); } to { transform: var(--from); } }
noscript { display: block; max-width: 560px; margin: 0 auto; padding: 24px; line-height: 1.6; }

/* ---------- one page at a time: tablets and phones ---------- */
@media (max-width: 1099px) { /* keep in step with `solo` in book.js */
  :root { --pw: min(calc(100vw - 44px), 620px); --ph: max(calc(var(--pw) / 1.36), min(calc(var(--pw) / .9), calc(100dvh - 330px))); } /* never flatter than 1.36:1, so a phone held sideways scrolls instead of squashing the page; on a tall tablet the page stands up like a book's */
  .scene { width: var(--pw); }
  .book { inset: 0 auto 0 0; width: calc(var(--pw) * 2); --shift: -50%; }
  .solo-left .book { --shift: 0%; }
  .is-closed .book { --shift: -50%; --tilt: 0deg; --turn: 0deg; } /* a tilted cover would hang over the controls */
  .scene { margin-bottom: 10px; }
  .is-closed .scene { --shadow-w: 1; }
  .zone { width: 6%; }
  .room { display: none; } /* no room for scenery: the table and its light stay */
  .toplinks > .speaker { width: 46px; margin: 0 0 0 8px; } .speaker .cord { display: none; } /* smaller, and no cord across a narrow screen */
  .flag { width: 2.5em; left: calc(100% - .75em); pointer-events: none; } .flag span { color: transparent !important; } /* markers here: the strip below is the control */
  .btn, .toplinks > a, .toplinks > button { min-height: 44px; }
  /* One page at a time, and under it one compact dock: the thread with its arrows, then the industries in a row that
     scrolls sideways. Closing the book is her name in the top corner, so there is no Close button taking a row. */
  .for-wide { display: none; } .for-touch { display: inline; }
  .stage:not(.is-closed) .toggle { display: none; } .stage:not(.is-closed):not(.has-thread) .bar2 { display: none; }
  .leaf.over .flag { display: none; } /* bookmarks on turned leaves would sit beside a left-hand page as clutter */
  .strip { display: flex; align-items: center; gap: 8px; overflow-x: auto; padding: 2px 28px 6px 16px; max-width: 100vw; scrollbar-width: none; scroll-padding-left: 16px;
    -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 36px), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 36px), transparent); }
  .strip::-webkit-scrollbar { display: none; }
  .strip-lab { flex: none; font-family: var(--mono); font-size: 10.5px; letter-spacing: .14em; text-transform: uppercase; color: var(--sub); }
  .strip .pill { font-size: 13px; padding: 6px 13px 6px 11px; min-height: 40px; box-shadow: 1px 2px 0 rgba(58, 32, 10, .28); }
  .strip .pill[aria-pressed="true"] { background: var(--c); color: #fff; } .strip .pill[aria-pressed="true"]::before { background: #fff; }
  .step { flex: 0 0 44px; } .step .to { display: none; } .line { flex: 1 1 0; } .step .arr { width: 44px; height: 44px; }
  .thread .x { width: 44px; height: 44px; }
  .toplinks > button[data-go] { display: none; } .toplinks > button[data-go="cover"] { display: inline-flex; }
  .q-a, .fold-l > i, .fold-b > i, .flat { border-radius: 0 !important; }
  .clip { top: -30px; left: 20px; } .tabs { bottom: auto; top: 10px; right: 14px; } .tab { border-radius: 999px; border-bottom: 1.5px solid var(--ink); min-height: 44px; } /* no room above a sheet that fills the window: the tabs sit on it */
}
@media (max-width: 600px) {
  :root { --ph: calc(var(--pw) / .7); } /* a full portrait page even on short phones: the screen scrolls rather than the page clipping */
  .pg { font-size: clamp(12px, 3.75cqw, 15px); padding: 5.2cqh 7cqw 7cqh; }
  .intro h2 { font-size: 2em; } .intro .strength { font-size: 1.18em; } .ch h2 { font-size: 2em; white-space: normal; } .ch.long h2 { font-size: 1.65em; } .ch .run { flex-wrap: wrap; gap: .25em 1em; } .epi h2 { font-size: 1.8em; } .letter { width: 92%; padding: 1.3em 1.2em 1.1em; } .signed { grid-template-columns: 1fr; gap: .5em; }
  .quote p { font-size: 1.3em; } .trio { grid-template-columns: 1fr; gap: .4em; } .away { padding: .38em .6em .4em; } .away b { display: inline; padding-right: .3em; } .away span { display: inline; } .away .ic { top: .35em; } .away.poems { padding-left: 1.55em; }
  .abt .duo { grid-template-columns: 1fr; } .abt .duo .lab2 { margin-top: .6em; } .abt .rows span { font-size: .8em; } .thr { grid-template-columns: 1fr; gap: 0; min-height: 0; margin-top: .2em; } .thr.head .kind-of { display: none; } .idx .lede { margin-bottom: .3em; }
  .log li { grid-template-columns: 3.4em 1fr; } .log p { grid-column: 2; }
  :root { --top: 58px; } .top { padding: 0 14px; gap: 10px; } .toplinks a:not(.cta) { display: none; } .brand { font-size: 20px; }
  .toplinks > button[data-go="cover"] { display: none !important; } /* her name is the way back to the cover */
  .toplinks .cta { white-space: nowrap; padding: 0 15px; margin-left: 4px; } .toplinks > .speaker { width: 42px; margin: 0 2px; }
  .stage { gap: 10px; justify-content: safe center; padding-top: calc(var(--top) + 8px); } .bar { gap: 6px; } /* what is left of a tall screen goes above and below, not all at the bottom */
  .task { font-size: 13px; } .toc button { padding: .3em .3em; } .toc h2 { font-size: 1.62em; white-space: nowrap; } .starred { font-size: 1.06em; } .aside { display: none; }
  .brief { margin-top: .55em; line-height: 1.4; } .ch .notes { margin-top: .85em; } .intro .acts .btn { padding: .5em 1em; } .intro .sign { font-size: 1.55em !important; }
}
@media (max-width: 360px) {
  :root { --ph: calc(var(--pw) / .66); } /* the type cannot get smaller here, so the page gets a little taller */
  .brand { font-size: 18px; } .toplinks .cta { padding: 0 12px; }
}
@media (prefers-reduced-motion: reduce) {
  :root { --dur: 1ms; }
  .intro-anim .flag, .intro-anim .scene, .intro-anim .prop .in, .listen img, .light b, .steam svg, .speaker .body, .speaker .glow, .waves i, .bloom, .sway, .cat .breath, .cat .tail, .cat .ears, .sc-a, .sc-b, .glint, .c-clip *, .beads path, .peel { animation: none !important; }
  .reader .sheet, .reader .fold-l, .reader .fold-b, .reader .flat, .reader .fold-l > i::before, .reader .fold-b > i::before { animation: none !important; } .reader-dim, .tabs, .clip { transition: none !important; }
  .reader.is-open .fold-l, .reader.is-open .fold-b { transform: none; visibility: visible; } .reader.is-open .flat { visibility: visible; }
}
  .steam svg { opacity: .7; }
  .is-closed .book { --tilt: 0deg; --turn: 0deg; }
  .prop .in { transition: none; }
}
