/* Future Fission. Hand-written, no framework. */

@font-face { font-family: "Bricolage"; src: url(fonts/bricolage.woff2) format("woff2"); font-weight: 200 800; font-stretch: 75% 100%; font-display: swap; }
@font-face { font-family: "Instrument"; src: url(fonts/instrument.woff2) format("woff2"); font-weight: 400 700; font-display: swap; }
@font-face { font-family: "Instrument"; src: url(fonts/instrument-italic.woff2) format("woff2"); font-weight: 400 700; font-style: italic; font-display: swap; }
@font-face { font-family: "Fraunces"; src: url(fonts/fraunces.woff2) format("woff2"); font-weight: 400 700; font-display: swap; }
@font-face { font-family: "Fraunces"; src: url(fonts/fraunces-italic.woff2) format("woff2"); font-weight: 400 700; font-style: italic; font-display: swap; }

:root {
  --paper: #f3ece0;
  --paper-deep: #e8dcc8;
  --ink: #241b20;
  --ink-soft: #64555b;
  --rule: #d6c8b1;
  --red: #ed2f59;
  --pink: #f06277;
  --red-ink: #c81d45;

  --dusk: #151a2b;
  --dusk-2: #1d2438;
  --lantern: #ffd36b;
  --wood: #2b1a13;
  --wood-2: #3a2419;
  --candle: #f2b84b;
  --cream: #f6e9d2;

  --mark-a: #ed2f59;
  --mark-b: #f06277;
  --grain: .35;
  --grain-blend: multiply;

  --gutter: clamp(16px, 4.5vw, 56px);
  --max: 1240px;
  --ease-out: cubic-bezier(.16, 1, .3, 1);
  --ease-spring: cubic-bezier(.34, 1.56, .64, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; overflow-x: clip; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font: 400 1.0625rem/1.6 "Instrument", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased; overflow-x: clip;
}
img, video, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration-thickness: 1.5px; text-underline-offset: .18em; }
a:hover { color: var(--red-ink); }
button { font: inherit; color: inherit; }
::selection { background: var(--red); color: var(--paper); }
:focus-visible { outline: 2.5px solid var(--red); outline-offset: 3px; border-radius: 6px; }

.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 max(var(--gutter), env(safe-area-inset-right)) 0 max(var(--gutter), env(safe-area-inset-left)); }
.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: var(--paper); padding: 8px 12px; z-index: 50; }
.skip:focus { left: 8px; }

/* night: the owner prefers the black and white logo on dark */
@media (prefers-color-scheme: dark) {
  :root {
    --paper: #121014; --paper-deep: #1b171b; --ink: #f1e9dd; --ink-soft: #a99da1; --rule: #2d272b;
    --red-ink: #ff6f8a; --mark-a: #f4efe7; --mark-b: #b9b4ae; --grain: .5; --grain-blend: soft-light;
  }
  .band.pl { --dusk: #1b2340; }
  .lost a.home { background: var(--ink); color: var(--paper); }
}
.fa { fill: var(--mark-a); transition: fill .4s; }
.fb { fill: var(--mark-b); transition: fill .4s; }
.fbs { stroke: var(--mark-b); }
.stage:hover .ring .fb { fill: var(--red); }
.stage, .piece, .shelf, .vial { -webkit-tap-highlight-color: transparent; -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; touch-action: manipulation; }
.piece { touch-action: none; }

/* paper grain, drawn once, never animated */
body {
  background-color: var(--paper);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .5 0 0 0 0 .42 0 0 0 0 .36 0 0 0 .09 0'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: 160px 160px;
}

/* ---------- header ---------- */
.top { position: relative; z-index: 5; }
.top .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-top: 18px; padding-bottom: 18px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.brand img { height: 40px; width: auto; }
.nav { display: flex; gap: clamp(14px, 3vw, 30px); font-weight: 600; font-size: .95rem; }
.nav a { text-decoration: none; position: relative; padding: 4px 0; }
.nav a::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: var(--red); transform: scaleX(0); transform-origin: left; transition: transform .35s var(--ease-out); }
.nav a:hover::after { transform: scaleX(1); }
.nav a:hover { color: var(--ink); }

/* ---------- hero ---------- */
.hero { position: relative; padding: clamp(12px, 3vw, 30px) 0 clamp(64px, 9vw, 110px); overflow: clip; }
.hero .wrap { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); align-items: center; gap: clamp(16px, 4vw, 56px); }
.hero h1 {
  font-family: "Bricolage", sans-serif; font-weight: 720; font-stretch: 84%;
  font-size: clamp(2.6rem, 6.6vw, 6.5rem); line-height: .92; letter-spacing: -.008em; margin: 0 0 .32em;
  font-variation-settings: "opsz" 96;
}
.hero h1 .r { color: var(--red); }
.hero h1 .w { display: inline-block; white-space: nowrap; }
.hero .lede { max-width: 33rem; font-size: clamp(1.06rem, 1.5vw, 1.22rem); color: var(--ink-soft); margin: 0; }
.hero .lede strong { color: var(--ink); font-weight: 600; }
.poke { margin-top: 22px; font-size: .92rem; color: var(--ink-soft); display: flex; align-items: center; gap: 10px; min-height: 1.6em; }
.poke svg { width: 46px; height: 22px; flex: none; color: var(--red); }
.poke .count { font-variant-numeric: tabular-nums; }

.stage { position: relative; aspect-ratio: 1507 / 1791; width: min(100%, 540px); justify-self: end; margin-right: calc(var(--gutter) * -.6); touch-action: manipulation; }
.hero h1 .dot { display: inline-block; width: .2em; height: .2em; margin-left: .05em; vertical-align: baseline; overflow: visible; }
.js .hero h1 .dot { animation: dot .7s var(--ease-spring) 1.5s both; }
@keyframes dot { 0% { transform: translateY(-1.4em) scale(.4); opacity: 0; } 60% { transform: translateY(0) scale(1.25); opacity: 1; } 100% { transform: none; } }
.stage .tilt { width: 100%; height: 100%; will-change: transform; transition: transform .6s var(--ease-out); }
.stage .tilt { position: relative; }
.stage .part { position: absolute; inset: 0; pointer-events: none; }
.stage .part svg { width: 100%; height: 100%; overflow: visible; }
.stage .ring path { pointer-events: visiblePainted; cursor: pointer; }
/* transform origins sit on each shape's own centre, in % of the whole mark */
.stage .half-l { transform-origin: 24.6% 40.3%; } .stage .half-r { transform-origin: 75.4% 40.3%; }
.stage .bar-l { transform-origin: 37.1% 31.8%; } .stage .bar-r { transform-origin: 62.9% 31.8%; }
.stage .wedge-l { transform-origin: 40.1% 3.7%; } .stage .wedge-r { transform-origin: 59.9% 3.7%; }
.stage .ring { transform-origin: 50% 89.7%; }
.stage-btn { position: absolute; left: 36%; width: 28%; bottom: 0; height: 22%; border: 0; background: transparent; cursor: pointer; border-radius: 50%; }

/* intro: the logo assembles the same way it does in the games */
.js .intro .half-l { animation: in-l 1s var(--ease-spring) .1s both; }
.js .intro .half-r { animation: in-r 1s var(--ease-spring) .1s both; }
.js .intro .wedge { animation: in-up .5s var(--ease-out) .55s both; }
.js .intro .bar-l { animation: bar .55s var(--ease-spring) .62s both; }
.js .intro .bar-r { animation: bar .55s var(--ease-spring) .62s both; }
.js .intro .ring { animation: drop 1.05s linear .5s both; }
.js .intro-text > * { animation: rise .9s var(--ease-out) both; }
.js .intro-text > :nth-child(1) { animation-delay: .15s; }
.js .intro-text > :nth-child(2) { animation-delay: .32s; }
.js .intro-text > :nth-child(3) { animation-delay: 1.4s; }
@keyframes in-l { from { transform: translateX(-34.5%) rotate(-8deg); opacity: 0; } }
@keyframes in-r { from { transform: translateX(34.5%) rotate(8deg); opacity: 0; } }
@keyframes in-up { from { transform: translateY(-8.8%); opacity: 0; } }
@keyframes bar { from { transform: scaleX(0); } }
@keyframes rise { from { transform: translateY(26px); opacity: .01; } }
@keyframes drop {
  0% { transform: translateY(-185%); opacity: 0; animation-timing-function: cubic-bezier(.55, 0, 1, .45); }
  8% { opacity: 1; }
  52% { transform: translateY(0); animation-timing-function: cubic-bezier(0, .55, .45, 1); }
  68% { transform: translateY(-8.6%); animation-timing-function: cubic-bezier(.55, 0, 1, .45); }
  82% { transform: translateY(0); animation-timing-function: cubic-bezier(0, .55, .45, 1); }
  91% { transform: translateY(-2.1%); animation-timing-function: cubic-bezier(.55, 0, 1, .45); }
  100% { transform: translateY(0); }
}

/* ---------- section headings shared ---------- */
.kicker { font-weight: 600; font-size: .82rem; letter-spacing: .14em; text-transform: uppercase; margin: 0 0 14px; }

/* ---------- reveal on scroll ---------- */
.js .rv { opacity: 0; transform: translateY(34px); transition: opacity .9s var(--ease-out), transform .9s var(--ease-out); }
.js .rv.in { opacity: 1; transform: none; }
.js .rv.d1 { transition-delay: .08s; } .js .rv.d2 { transition-delay: .16s; } .js .rv.d3 { transition-delay: .24s; }

/* ---------- game bands ---------- */
.band { position: relative; color: var(--cream); isolation: isolate; }
.band .wrap { position: relative; display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: clamp(20px, 3vw, 40px); }
.band .copy { grid-column: 1 / span 5; align-self: start; position: sticky; top: 40px; }
.band .show { grid-column: 6 / span 7; }
.band h2 { font-family: "Fraunces", serif; font-weight: 600; font-size: clamp(3rem, 7vw, 6rem); line-height: .95; letter-spacing: -.02em; margin: 0 0 .25em; font-variation-settings: "opsz" 144, "SOFT" 50; }
.band .hook { font-family: "Fraunces", serif; font-style: italic; font-size: clamp(1.25rem, 2.1vw, 1.6rem); line-height: 1.3; margin: 0 0 1.1em; }
.band p { max-width: 34rem; }
.band .facts { margin: 26px 0 0; padding: 18px 0 0; border-top: 1px solid rgba(246, 233, 210, .18); font-size: .95rem; display: grid; grid-template-columns: auto 1fr; gap: 6px 18px; }
.band .facts dt { opacity: .6; }
.band .facts dd { margin: 0; }
.store { display: inline-flex; align-items: center; gap: 12px; margin-top: 26px; padding: 10px 18px 10px 12px; border-radius: 14px; border: 1.5px solid rgba(246, 233, 210, .35); font-weight: 600; font-size: .95rem; }
.store img { width: 40px; height: 40px; border-radius: 10px; }
.store small { display: block; font-weight: 400; opacity: .7; font-size: .8rem; }

/* torn paper edge between the page and Paperlight's night */
.band.pl { background: radial-gradient(1200px 700px at 80% 20%, #232c48 0%, transparent 60%), var(--dusk); padding: clamp(90px, 12vw, 150px) 0 clamp(70px, 10vw, 130px); margin-top: -2px; }
.band.pl::before { content: ""; position: absolute; left: 0; right: 0; top: -1px; height: 46px; background: var(--paper); z-index: -1;
  clip-path: polygon(0 0, 100% 0, 100% 38%, 97% 52%, 93.5% 41%, 90% 63%, 86% 47%, 82.5% 70%, 78% 50%, 74% 58%, 70% 40%, 66.5% 61%, 62% 45%, 58% 72%, 54.5% 52%, 50% 60%, 46% 39%, 42.5% 66%, 38% 48%, 34% 57%, 30.5% 36%, 26% 62%, 22% 44%, 18.5% 70%, 14% 51%, 10% 59%, 6.5% 37%, 3% 55%, 0 44%); }
.band.pl .kicker { color: var(--lantern); }

.band.tc { background: radial-gradient(900px 600px at 15% 30%, rgba(242, 184, 75, .16), transparent 65%), linear-gradient(#24150f, var(--wood) 30%, #22140e); padding: clamp(90px, 12vw, 150px) 0 clamp(80px, 10vw, 140px); }
.band.tc .copy { grid-column: 8 / span 5; grid-row: 1; }
.band.tc .show { grid-column: 1 / span 7; grid-row: 1; }
.band.tc .kicker { color: var(--candle); }
.band.tc h2 { letter-spacing: .02em; font-weight: 500; }

/* ---------- phones ---------- */
.phones { position: relative; height: clamp(420px, 52vw, 620px); }
.phone { position: absolute; width: clamp(150px, 19vw, 248px); aspect-ratio: 9 / 16; border-radius: clamp(20px, 2.4vw, 30px); background: #0b0a0c; padding: 6px; box-shadow: 0 30px 60px -20px rgba(0, 0, 0, .55), 0 0 0 1px rgba(255, 255, 255, .06) inset; }
.phone img, .phone video { width: 100%; height: 100%; object-fit: cover; border-radius: calc(clamp(20px, 2.4vw, 30px) - 6px); background: #111; }
.phones .p1 { left: 2%; top: 9%; rotate: -7deg; }
.phones .p2 { left: 34%; top: 0; z-index: 2; }
.phones .p3 { left: 66%; top: 12%; rotate: 6deg; }
.band.tc .phones .p1 { left: 0; top: 14%; rotate: -5deg; }
.band.tc .phones .p2 { left: 31%; top: 2%; }
.band.tc .phones .p3 { left: 63%; top: 10%; rotate: 7deg; }
@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) {
    .phones .phone { animation: drift linear both; animation-timeline: view(); animation-range: entry 0% exit 100%; }
    .phones .p1 { --dy: 70px; } .phones .p2 { --dy: -40px; } .phones .p3 { --dy: 110px; }
    @keyframes drift { from { translate: 0 var(--dy); } to { translate: 0 calc(var(--dy) * -1); } }
  }
}

/* ---------- mini Paperlight ---------- */
.toy { margin-top: clamp(30px, 5vw, 60px); position: relative; }
.note { font-family: "Fraunces", serif; font-style: italic; font-size: clamp(1.05rem, 1.6vw, 1.25rem); margin: 0 0 18px; max-width: none; }
.note::before { content: "\2198"; font-style: normal; display: inline-block; margin-right: 8px; opacity: .7; }
.toy-foot { display: flex; align-items: center; gap: 18px; margin-top: 16px; font-size: .92rem; min-height: 40px; }
.toy-foot span { opacity: .75; font-variant-numeric: tabular-nums; }
.toy-foot .again { margin: 0; }
.toy-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 16px; font-size: .92rem; }
.toy-head b { font-family: "Fraunces", serif; font-weight: 600; font-size: 1.15rem; }
.toy-head span { opacity: .65; }
.pl-toy { --cell: clamp(30px, 3.5vw, 46px); --gap: clamp(3px, .5vw, 5px); display: flex; align-items: flex-end; gap: clamp(18px, 4vw, 44px); flex-wrap: wrap; }
.board { display: grid; grid-template-columns: repeat(8, var(--cell)); grid-auto-rows: var(--cell); gap: var(--gap); padding: var(--gap); border-radius: 14px; background: #0e1220; position: relative; box-shadow: 0 0 0 1px rgba(255, 255, 255, .05), 0 30px 90px -20px rgba(255, 196, 90, .18); }
.cell { border-radius: 24%; background: rgba(255, 255, 255, .045); }
.tile { --c: #ffc75a; border-radius: 24%; background: var(--c); background:
    repeating-linear-gradient(0deg, rgba(255, 255, 255, 0) 0 22%, rgba(120, 60, 0, .08) 22% 25%),
    radial-gradient(circle at 50% 45%, #fffbe9 0%, var(--c) 58%, color-mix(in srgb, var(--c), #5a2a10 28%) 100%);
  box-shadow: inset 0 0 0 2px color-mix(in srgb, var(--c), #3a1a08 35%), 0 0 18px -4px var(--c); }
.cell.tile { transform-origin: center; }
.cell.land { animation: land .32s var(--ease-spring); }
@keyframes land { from { transform: scale(.6); } }
.cell.burn { animation: burn .42s ease-in forwards; }
@keyframes burn { 0% { filter: brightness(1); } 35% { filter: brightness(1.8); transform: scale(1.08); } 100% { transform: scale(.2); opacity: 0; } }
.tray { display: flex; flex-direction: column; align-items: center; min-width: calc(var(--cell) * 3 + var(--gap) * 2); }
.piece { display: grid; grid-template-columns: repeat(3, var(--cell)); grid-auto-rows: var(--cell); gap: var(--gap); border: 0; padding: 0; background: none; cursor: grab; touch-action: none; position: relative; z-index: 3; }
.piece:active { cursor: grabbing; }
.piece .tile, .piece .nil { width: var(--cell); height: var(--cell); }
.piece.drag { transition: none; filter: drop-shadow(0 18px 18px rgba(0, 0, 0, .45)); }
.piece.home { transition: transform .45s var(--ease-spring); }
.piece.gone { visibility: hidden; }
.tray small { opacity: .6; font-size: .8rem; text-align: center; }
.chip { position: absolute; left: 50%; top: 38%; translate: -50% -50%; font-family: "Fraunces", serif; font-weight: 600; font-size: clamp(1.3rem, 2.6vw, 2rem); padding: .2em .8em; border-radius: 999px; background: #1a2037; border: 1.5px solid var(--lantern); color: var(--cream); pointer-events: none; opacity: 0; white-space: nowrap; z-index: 4; }
.chip em { font-style: normal; color: var(--lantern); }
.chip.pop { animation: chip 1.6s var(--ease-out) forwards; }
@keyframes chip { 0% { opacity: 0; transform: scale(.6); } 15% { opacity: 1; transform: scale(1.06); } 25% { transform: scale(1); } 80% { opacity: 1; } 100% { opacity: 0; transform: translateY(-30px); } }
.again[disabled] { visibility: hidden; }
.again { white-space: nowrap; border: 1.5px solid rgba(246, 233, 210, .3); background: none; border-radius: 999px; padding: 8px 18px; cursor: pointer; font-weight: 600; font-size: .9rem; opacity: 0; pointer-events: none; transition: opacity .4s, border-color .2s; }
.again.on { opacity: 1; pointer-events: auto; }
.again:hover { border-color: var(--lantern); }

/* ---------- mini Tincture ---------- */
.tc-toy { --vw: clamp(54px, 8vw, 78px); }
.shelf { position: relative; display: flex; justify-content: center; gap: clamp(16px, 4vw, 38px); padding: 70px 10px 0; }
.shelf::after { content: ""; position: absolute; left: -6px; right: -6px; bottom: -14px; height: 16px; border-radius: 3px; background: linear-gradient(#6b4129, #4a2a19 60%, #2c180e); box-shadow: 0 10px 18px -6px rgba(0, 0, 0, .6); }
.vial { position: relative; width: var(--vw); height: calc(var(--vw) * 2.55); border: 0; padding: 0; background: none; cursor: pointer; z-index: 1; transition: transform .28s var(--ease-out); }
.vial.up { transform: translateY(-22px); }
.vial .glass { position: absolute; inset: 0; border-radius: 10px 10px calc(var(--vw) * .45) calc(var(--vw) * .45); border: 3px solid rgba(240, 226, 205, .55); border-top-color: rgba(240, 226, 205, .3); overflow: hidden; background: linear-gradient(90deg, rgba(255, 255, 255, .05), rgba(255, 255, 255, .02) 40%, rgba(255, 255, 255, .07)); }
.vial .glass::after { content: ""; position: absolute; left: 16%; top: 12%; width: 9%; height: 60%; border-radius: 99px; background: rgba(255, 255, 255, .28); }
.liquid { position: absolute; left: 0; right: 0; bottom: 0; top: 14%; display: flex; flex-direction: column-reverse; }
.unit { height: 25%; flex: none; background: var(--c); transform-origin: 50% 100%; box-shadow: inset 0 3px 0 rgba(255, 255, 255, .18); }
.unit.drain { animation: drain .36s ease-in forwards; transform-origin: 50% 0; }
.unit.fill { animation: fill .38s ease-out both; }
@keyframes drain { to { transform: scaleY(0); } }
@keyframes fill { from { transform: scaleY(0); } }
.cork { position: absolute; left: 14%; right: 14%; top: -10px; height: 22px; border-radius: 4px 4px 3px 3px; background: linear-gradient(#c98a4b, #9a6031); box-shadow: inset 0 -3px 0 rgba(0, 0, 0, .2); animation: cork .45s var(--ease-spring) both; }
@keyframes cork { from { transform: translateY(-60px) rotate(-14deg); opacity: 0; } }
.stream { position: absolute; width: 6px; border-radius: 3px; transform-origin: 50% 0; pointer-events: none; z-index: 3; animation: stream .62s ease-in-out forwards; }
@keyframes stream { 0% { transform: scaleY(0); } 25%, 70% { transform: scaleY(1); } 100% { transform: scaleY(1) translateY(100%); opacity: 0; } }
.tc-msg { min-height: 1.6em; margin-top: 34px; font-size: .95rem; display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.tc-msg .again { margin: 0; opacity: 1; pointer-events: auto; }
.tc-msg .again:hover { border-color: var(--candle); }

/* ---------- studio ---------- */
.studio { padding: clamp(80px, 12vw, 150px) 0 clamp(60px, 9vw, 110px); }
.studio .wrap { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: clamp(20px, 3vw, 40px); }
.studio h2 { grid-column: 1 / span 5; grid-row: 1; font-family: "Bricolage", sans-serif; font-weight: 760; font-stretch: 80%; font-size: clamp(2.4rem, 5.6vw, 4.8rem); line-height: .95; letter-spacing: -.02em; margin: 0; }
.studio h2 .r { color: var(--red); }
.studio .body { grid-column: 7 / span 6; grid-row: 1 / span 2; font-size: clamp(1.06rem, 1.4vw, 1.2rem); }
.studio .body p:first-child { margin-top: 0; }
.studio .hand { font-family: "Fraunces", serif; font-style: italic; color: var(--red-ink); }
.mail { display: inline-block; margin-top: 10px; font-family: "Bricolage", sans-serif; font-weight: 700; font-stretch: 85%; font-size: clamp(1.4rem, 3.4vw, 2.4rem); text-decoration: none; background: linear-gradient(var(--red), var(--red)) 0 100% / 100% 3px no-repeat; transition: background-size .45s var(--ease-out), color .2s; padding-bottom: 4px; word-break: break-all; }
.mail:hover { color: var(--paper); background-size: 100% 100%; }

/* the logo's construction drawing, drawn in when it scrolls into view */
.sketch { grid-column: 1 / span 4; grid-row: 2; margin: 10px 0 0; color: var(--ink-soft); }
.sketch svg { width: 100%; max-width: 320px; height: auto; overflow: visible; }
.sketch .guides { fill: none; stroke: var(--rule); stroke-width: 5; stroke-dasharray: 18 22; }
.sketch .ink > * { fill: none; stroke: var(--red); stroke-width: 7; stroke-linejoin: round; stroke-dasharray: 1; stroke-dashoffset: 0; }
.js .sketch .ink > * { stroke-dashoffset: 1; transition: stroke-dashoffset 2.2s cubic-bezier(.45, .05, .25, 1); }
.js .sketch.in .ink > * { stroke-dashoffset: 0; }
.js .sketch.in .ink > :nth-child(2) { transition-delay: .25s; } .js .sketch.in .ink > :nth-child(n+3) { transition-delay: .6s; } .js .sketch.in .ink > :nth-child(n+7) { transition-delay: 1s; }
.sketch figcaption { font-family: "Fraunces", serif; font-style: italic; font-size: .98rem; margin-top: 14px; max-width: 18rem; }

/* Paperlight: screenshots pinned up like paper prints */
.band.pl .phone { background: #f4ecdd; padding: 7px 7px 30px; border-radius: 3px; box-shadow: 0 24px 50px -18px rgba(0, 0, 0, .6); }
.band.pl .phone img { border-radius: 2px; }
.band.pl .phone::before { content: ""; position: absolute; top: -13px; left: 50%; width: 74px; height: 24px; translate: -50% 0; rotate: -4deg; background: rgba(255, 211, 107, .62); box-shadow: 0 1px 2px rgba(0, 0, 0, .2); }
.band.pl .phones .p2::before { rotate: 3deg; background: rgba(111, 227, 207, .55); }
.band.pl .phones .p3::before { rotate: -7deg; background: rgba(245, 143, 181, .55); }
.band.pl .phones .p2 { rotate: 2deg; }

/* Tincture: phones standing on one shelf */
.band.tc::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 12px; background: linear-gradient(#7a4a2e, #4a2a19 70%, #2c180e); box-shadow: 0 6px 16px rgba(0, 0, 0, .45); }
.band.tc .phones .phone { top: auto; bottom: 30px; rotate: 0deg; animation: none; }
.band.tc .phones .p1 { left: 2%; } .band.tc .phones .p2 { left: 34%; scale: 1.06; transform-origin: 50% 100%; z-index: 2; } .band.tc .phones .p3 { left: 66%; }
.band.tc .phones::after { content: ""; position: absolute; left: -3%; right: -3%; bottom: 12px; height: 18px; border-radius: 3px; background: linear-gradient(#7a4a2e, #4a2a19 60%, #2c180e); box-shadow: 0 16px 24px -8px rgba(0, 0, 0, .7); }

/* ---------- Foresky: a clear afternoon sky, phones hung from a cloud ---------- */
.band.fs {
  --sky-ink: #12203d; --sky-top: #6c9ee0; --sky-mid: #a9c8ef; --sky-low: #d8e7f7; --horizon: #f5e2c8; --hill: #8cbf78; --hill-2: #6fa65f;
  color: var(--sky-ink); overflow: clip;
  background: radial-gradient(700px 420px at 88% 8%, rgba(255, 246, 214, .55), transparent 70%), linear-gradient(var(--sky-top), var(--sky-mid) 38%, var(--sky-low) 72%, var(--horizon) 94%);
  padding: clamp(110px, 13vw, 170px) 0 clamp(120px, 14vw, 190px);
}
/* a cloud bank where the shop shelf ends, and hills where the sky meets the page */
.band.fs::before { content: ""; position: absolute; left: -40px; right: -40px; top: -1px; height: 64px; z-index: -1;
  background: radial-gradient(closest-side, #fff 72%, rgba(255, 255, 255, 0)) 0 -38px / 120px 96px repeat-x, radial-gradient(closest-side, rgba(255, 255, 255, .85) 70%, rgba(255, 255, 255, 0)) 60px -20px / 150px 84px repeat-x; }
.band.fs::after { content: ""; position: absolute; left: -10%; right: -10%; bottom: -1px; height: clamp(60px, 8vw, 110px); z-index: -1;
  background: radial-gradient(60% 100% at 22% 100%, var(--hill) 98%, transparent 100%), radial-gradient(55% 90% at 80% 100%, var(--hill-2) 98%, transparent 100%), linear-gradient(transparent 70%, var(--hill-2) 70%); }
.band.fs .copy { grid-column: 1 / span 5; }
.band.fs .show { grid-column: 6 / span 7; }
.band.fs .kicker { color: #1d4f9e; }
.band.fs h2 { font-weight: 700; letter-spacing: -.035em; font-variation-settings: "opsz" 144, "SOFT" 100, "WONK" 1; }
.band.fs .facts { border-top-color: rgba(18, 32, 61, .2); }
.band.fs .facts dt { opacity: .72; }
.band.fs .store { border-color: rgba(18, 32, 61, .3); background: rgba(255, 255, 255, .35); }
.band.fs a:hover, .band.fs .again:hover { color: var(--sky-ink); }
.fs-puff { position: absolute; z-index: -1; pointer-events: none; height: auto; opacity: .9; }
.fs-puff.a { width: clamp(150px, 20vw, 259px); left: 31%; top: 5%; }
.fs-puff.b { width: clamp(130px, 17vw, 240px); right: 4%; top: 64%; opacity: .7; }

/* phones on strings: a taller phone, so its own aspect */
.band.fs .phones { --pw: clamp(140px, 17vw, 226px); --drop: clamp(84px, 9.5vw, 124px); height: calc(var(--pw) * 20 / 9 + var(--drop) + 46px); }
.band.fs .fs-hang { position: absolute; top: 0; height: auto; z-index: 3; pointer-events: none; }
.band.fs .fs-hang.a { left: 6%; width: 46%; }
.band.fs .fs-hang.b { right: 2%; top: 8px; width: 34%; }
.band.fs .phone { width: var(--pw); aspect-ratio: 9 / 20; top: calc(var(--drop) + var(--y, 0px)); --str: calc(var(--drop) + var(--y, 0px) - 30px); rotate: 0deg; border-radius: clamp(18px, 2.2vw, 28px); background: #10172a; box-shadow: 0 28px 50px -22px rgba(20, 40, 80, .55), 0 0 0 1px rgba(255, 255, 255, .25) inset; transform-origin: 50% calc(var(--str) * -1); }
.band.fs .phone::before { content: ""; position: absolute; left: 50%; bottom: 100%; width: 1.5px; height: var(--str); translate: -50% 0; background: rgba(255, 255, 255, .85); }
.band.fs .phone::after { content: ""; position: absolute; left: 50%; top: -5px; width: 10px; height: 10px; translate: -50% 0; border-radius: 50%; background: radial-gradient(circle at 35% 30%, #fff, #cfe1f5 60%, #8fb0d8); box-shadow: 0 1px 2px rgba(20, 40, 80, .3); }
.band.fs .phone img { border-radius: calc(clamp(18px, 2.2vw, 28px) - 6px); background: #9cc0ea; }
.band.fs .phones .phone { animation: none; }
.band.fs .phones .p1 { left: 3%; --y: 34px; }
.band.fs .phones .p2 { left: 36%; --y: 0px; z-index: 2; }
.band.fs .phones .p3 { left: auto; right: 3%; --y: 46px; }
@media (prefers-reduced-motion: no-preference) {
  .js .band.fs .phones .phone { animation: sway 7s ease-in-out infinite alternate; }
  .js .band.fs .phones .p2 { animation-duration: 8.5s; animation-delay: -3s; }
  .js .band.fs .phones .p3 { animation-duration: 6.2s; animation-delay: -1.5s; }
  .js .fs-puff.a { animation: puff 38s ease-in-out infinite alternate; }
  .js .fs-puff.b { animation: puff 46s ease-in-out -12s infinite alternate-reverse; }
  /* the sky only moves while you can see it, so it costs nothing while you're up at the logo */
  .js .band.fs:not(.live) .phone, .js .band.fs:not(.live) .fs-puff { animation-play-state: paused; }
  @keyframes sway { from { rotate: -1.6deg; } to { rotate: 1.6deg; } }
  @keyframes puff { to { translate: 60px 0; } }
}

/* ---------- mini Foresky ---------- */
.fs-toy { --u: clamp(40px, calc((100vw - var(--gutter) * 2 - 28px) / 6), 60px); --top: 2.95; }
.fs-toy .note { max-width: 32rem; }
.fs-field { position: relative; width: calc(var(--u) * 6); height: calc(var(--u) * (var(--top) + 5)); margin: 0 0 0 10px; outline: none; touch-action: manipulation; -webkit-tap-highlight-color: transparent; user-select: none; -webkit-user-select: none; }
.fs-sky { position: absolute; left: -10px; right: -10px; top: 0; height: calc(var(--u) * (var(--top) - .2)); border-radius: 16px 16px 10px 10px; border: 1.5px solid rgba(255, 255, 255, .6);
  background: radial-gradient(closest-side, #fff 78%, rgba(255, 255, 255, 0)) calc(var(--u) * -.1) calc(var(--u) * -.42) / calc(var(--u) * .78) calc(var(--u) * .9) repeat-x,
    linear-gradient(90deg, transparent calc(50% - .75px), rgba(255, 255, 255, .9) calc(50% - .75px) calc(50% + .75px), transparent calc(50% + .75px)) 10px 0 / var(--u) 100% repeat-x,
    rgba(255, 255, 255, .26); }
.fs-bed { position: absolute; left: -8px; right: -8px; top: calc(var(--u) * var(--top) - 8px); height: calc(var(--u) * 5 + 16px); border-radius: 14px; background: #3f5568;
  box-shadow: 0 0 0 4px #f6eedd, 0 0 0 5.5px #d4ab55, 0 22px 40px -18px rgba(20, 40, 80, .6); touch-action: none; }
.fs-bed::before { content: ""; position: absolute; inset: 8px; background: radial-gradient(closest-side, rgba(255, 255, 255, .11) 86%, transparent 92%) 0 0 / var(--u) var(--u); }
.fs-pieces { position: absolute; inset: 0; pointer-events: none; }
.fs-p { position: absolute; left: 0; top: 0; width: var(--u); height: var(--u); transition: transform var(--t, 200ms) var(--e, cubic-bezier(.3, .7, .3, 1)); }
.fs-p i { position: absolute; inset: 5%; background: url(img/fs_charms.webp) 0 0 / 600% 100% no-repeat; transition: transform .25s var(--ease-out), opacity .25s; }
.fs-p.k1 i { background-position-x: 20%; } .fs-p.k2 i { background-position-x: 40%; } .fs-p.k3 i { background-position-x: 60%; } .fs-p.k4 i { background-position-x: 80%; } .fs-p.k5 i { background-position-x: 100%; }
.fs-p.sky i { transform: scale(.6); }
.fs-p.new i { animation: fs-new .35s var(--ease-out) both; }
@keyframes fs-new { from { opacity: 0; transform: translateY(-30%) scale(.4); } }
.fs-p.sel i { transform: scale(1.12); filter: drop-shadow(0 0 6px #fff7d0); }
.fs-p.land i { animation: fs-land .26s var(--ease-out); }
@keyframes fs-land { 0% { transform: scale(1.08, .86) translateY(6%); } 100% { transform: none; } }
.fs-p.pop i { animation: fs-pop .26s ease-in forwards; }
@keyframes fs-pop { 40% { transform: scale(1.25); filter: brightness(1.5); } 100% { transform: scale(.1); opacity: 0; } }
.fs-p.no i { animation: fs-no .3s ease-in-out; }
@keyframes fs-no { 25% { transform: translateX(-8%); } 75% { transform: translateX(8%); } }
.fs-cursor { position: absolute; left: 0; top: 0; width: var(--u); height: var(--u); border-radius: 12px; box-shadow: 0 0 0 2.5px #fff, 0 0 0 5px var(--sky-ink); opacity: 0; pointer-events: none; transition: transform .14s var(--ease-out); }
.fs-field:focus-visible .fs-cursor { opacity: 1; }
.fs-field:focus-visible .fs-sky { outline: 2.5px solid var(--sky-ink); outline-offset: 4px; }
.fs-chip { top: 52%; background: #fffaf0; border-color: #d4ab55; color: var(--sky-ink); font-size: clamp(1.15rem, 2.2vw, 1.6rem); }
.fs-chip em { color: #1d4f9e; }
.fs-toy .toy-foot span { opacity: .85; }
.fs-toy .again { border-color: rgba(18, 32, 61, .35); background: rgba(255, 255, 255, .4); }
.fs-toy .again:hover { border-color: var(--sky-ink); }
.sr { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }

/* dusk on the page, but it's still daytime up there: just less glare */
@media (prefers-color-scheme: dark) {
  .band.fs { --sky-top: #5f91d6; --sky-mid: #95b8e4; --sky-low: #c3d6ec; --horizon: #e4ceb2; --hill: #78a866; --hill-2: #5e9050; --sky-ink: #0e1a33; }
}

/* plain pages get a red torn strip under the header */
.doc { position: relative; }
.doc::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 12px; background: var(--red);
  clip-path: polygon(0 0, 100% 0, 100% 55%, 96% 80%, 92% 45%, 87% 90%, 82% 50%, 77% 75%, 72% 40%, 67% 85%, 62% 55%, 57% 95%, 52% 45%, 47% 70%, 42% 35%, 37% 80%, 32% 50%, 27% 90%, 22% 45%, 17% 75%, 12% 40%, 7% 85%, 3% 50%, 0 70%); }

/* ---------- footer ---------- */
.foot { border-top: 1px solid var(--rule); padding: 34px 0 40px; font-size: .9rem; color: var(--ink-soft); }
.foot .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 18px 30px; }
.foot img { height: 34px; width: auto; }
.foot nav { display: flex; gap: 22px; font-weight: 600; color: var(--ink); }
.foot nav a { text-decoration: none; display: inline-block; padding: 6px 0; }
.foot nav a:hover { text-decoration: underline; }

/* ---------- plain pages (privacy, support) ---------- */
.doc { padding: clamp(30px, 6vw, 70px) 0 90px; }
.doc .wrap { max-width: 860px; }
.doc h1 { font-family: "Bricolage", sans-serif; font-weight: 780; font-stretch: 80%; font-size: clamp(2.6rem, 7vw, 4.6rem); line-height: .95; letter-spacing: -.02em; margin: 0 0 .3em; }
.doc .meta { color: var(--ink-soft); margin: 0 0 2.2em; }
.doc h2 { font-family: "Bricolage", sans-serif; font-weight: 700; font-stretch: 88%; font-size: clamp(1.4rem, 2.6vw, 1.8rem); margin: 2.1em 0 .4em; }
.doc h3 { font-size: 1.08rem; margin: 1.6em 0 .3em; }
.doc .short { border-left: 4px solid var(--red); padding: 4px 0 4px 18px; font-size: 1.15rem; }
.doc table { width: 100%; border-collapse: collapse; margin: 1em 0; font-size: .98rem; }
.doc th, .doc td { text-align: left; padding: 10px 12px 10px 0; border-bottom: 1px solid var(--rule); vertical-align: top; }
.doc th { font-weight: 600; }
.lost { min-height: 72vh; display: grid; place-items: center; text-align: center; }
.lost .stage { width: 160px; margin: 0 auto 24px; }
/* the 404 puzzle */
.lost .wrap { max-width: 640px; }
.lost .puzzle { width: min(58vw, 240px); margin: clamp(70px, 12vh, 120px) auto 28px; aspect-ratio: 1507 / 1791; touch-action: none; user-select: none; -webkit-user-select: none; }
.lost svg { width: 100%; height: 100%; overflow: visible; }
.lost .part { cursor: grab; }
.lost .part.held { cursor: grabbing; }
.lost .part.home { cursor: default; }
.lost .ghost { fill: none; stroke: var(--rule); stroke-width: 9; stroke-dasharray: 22 18; }
.lost h1 { font-family: "Bricolage", sans-serif; font-weight: 720; font-stretch: 84%; font-size: clamp(2.4rem, 7vw, 4.2rem); line-height: .95; margin: 0 0 .3em; }
.lost p { color: var(--ink-soft); max-width: 26rem; margin: 0 auto 1.4em; }
.lost .count { font-family: "Fraunces", serif; font-style: italic; color: var(--ink); min-height: 1.5em; }
.lost a.home-link { display: inline-block; font-weight: 600; padding: 12px 22px; border-radius: 999px; background: var(--ink); color: var(--paper); text-decoration: none; }
.lost a.home-link:hover { background: var(--red); color: var(--paper); }
.lost.done svg { animation: whole .7s var(--ease-spring); }
@keyframes whole { 40% { transform: scale(1.08); } }
.lost a.home-link:focus-visible { outline-offset: 4px; }

/* ---------- fx canvas ---------- */
.fx { position: fixed; inset: 0; width: 100vw; height: 100vh; pointer-events: none; z-index: 40; }

/* ---------- small screens ---------- */
@media (max-width: 900px) {
  .hero .wrap { grid-template-columns: 1fr; }
  .stage { order: -1; width: min(52vw, 250px); margin-top: 6px; justify-self: start; margin-right: 0; }
  .poke svg { rotate: -100deg; width: 30px; }
  .sketch { grid-column: 1 / -1; grid-row: auto; display: flex; gap: 18px; align-items: end; }
  .sketch svg { max-width: 120px; }
  .studio .body { grid-row: auto; }
  .band .copy, .band.tc .copy { grid-column: 1 / -1; grid-row: auto; position: static; }
  .band .show, .band.tc .show { grid-column: 1 / -1; grid-row: auto; }
  .band.fs .copy, .band.fs .show { grid-column: 1 / -1; }
  .phones { height: clamp(250px, 66vw, 500px); }
  .phone { width: clamp(120px, 31vw, 220px); }
  .band.fs .phones { --pw: clamp(100px, 29vw, 200px); --drop: 16vw; }
  .fs-puff.a { display: none; } .fs-puff.b { top: auto; bottom: 16%; right: -6%; }
  .studio h2, .studio .body { grid-column: 1 / -1; }
}
@media (max-width: 520px) {
  .brand img { height: 32px; }
  .nav { font-size: .88rem; gap: 14px; }
  .nav .hide-s { display: none; }
  .pl-toy { justify-content: center; }
  .phones .p3, .band.tc .phones .p3 { left: auto; right: 0; }
  .toy-head { flex-direction: column; gap: 2px; }
  .shelf { gap: 12px; }
}

@media (prefers-reduced-motion: reduce) {
  .js .intro *, .js .intro-text > *, .js .hero h1 .dot { animation: none !important; }
  .cell.land, .cell.burn, .chip.pop, .cork, .stream, .unit.fill, .unit.drain, .fs-p i { animation-duration: 1ms !important; animation-delay: 0s !important; }
  .fs-p, .fs-p i, .fs-cursor { transition-duration: 1ms !important; }
  .js .sketch .ink > * { transition: none; }
  .js .rv { opacity: 1; transform: none; transition: none; }
}
