/* 渡鴉科技 — paper, ink and one red line. */
@font-face { font-family: "Muninn Serif TC"; src: url("/assets/fonts/serif-tc.woff2") format("woff2"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Muninn Sans TC"; src: url("/assets/fonts/sans-tc.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Muninn Sans TC"; src: url("/assets/fonts/sans-tc-bold.woff2") format("woff2"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Instrument Serif"; src: url("/assets/fonts/instrument-serif.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Plex Mono"; src: url("/assets/fonts/plex-mono.woff2") format("woff2"); font-weight: 400; font-display: swap; }

:root {
  --paper: #ebe5da;
  --paper-2: #e2dbce;
  --wall: #cfc4b5;
  --ink: #16130f;
  --ink-2: #4b453c;
  --ink-3: #6b645a;
  --rule: rgb(22 19 15 / .16);
  --red: #b8361f;
  --red-text: #a3301b;
  --red-on-ink: #f06a4c;
  --serif: "Muninn Serif TC", "Noto Serif TC", "Songti TC", serif;
  --serif-en: "Instrument Serif", "Muninn Serif TC", Georgia, serif;
  --sans: "Muninn Sans TC", -apple-system, BlinkMacSystemFont, "PingFang TC", "Noto Sans TC", sans-serif;
  --mono: "Plex Mono", ui-monospace, "SF Mono", Menlo, "Muninn Sans TC", "PingFang TC", monospace;
  --maxw: 1360px;
  --gutter: clamp(20px, 4vw, 64px);
  --inset: max(var(--gutter), calc((100vw - var(--maxw)) / 2));
  --thread-x: calc(var(--inset) - var(--gutter) / 2);
  --top-h: 76px;
  --ease: cubic-bezier(.2, .7, .1, 1);
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-padding-top: 24px; }
body {
  margin: 0; min-width: 320px; overflow-x: clip; min-height: 100svh; display: flex; flex-direction: column;
  background: var(--paper) url("/assets/img/grain.png");
  color: var(--ink); font: 400 17px/1.75 var(--sans);
  font-feature-settings: "palt" 0; text-rendering: optimizeLegibility; -webkit-font-smoothing: antialiased;
}
:lang(en) body, body:lang(en) { line-height: 1.6; }
img, video, svg { display: block; max-width: 100%; }
img { height: auto; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: .22em; }
a:hover { color: var(--red-text); }
:focus-visible { outline: 2px solid var(--red); outline-offset: 3px; border-radius: 2px; }
::selection { background: var(--red); color: var(--paper); }
h1, h2, h3 { margin: 0; font-family: var(--serif); font-weight: 700; letter-spacing: .01em; text-wrap: balance; }
:lang(en) :is(h1, h2, h3), :is(h1, h2, h3):lang(en) { font-family: var(--serif-en); font-weight: 400; letter-spacing: -.01em; }
p { margin: 0; text-wrap: pretty; }
strong { font-weight: 700; }
.nw { white-space: nowrap; }
.arr { display: inline-block; margin-left: .45em; transition: transform .35s var(--ease); }
a:hover .arr { transform: translateX(4px); }

.skip { position: absolute; left: 12px; top: -60px; z-index: 50; padding: 10px 14px; background: var(--ink); color: var(--paper); }
.skip:focus { top: 12px; }

/* ── header ─────────────────────────────────────────── */
.top { height: var(--top-h); display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-inline: var(--inset); position: relative; z-index: 5; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); }
.seal { width: 34px; height: 34px; flex: none; }
.brand-name { font: 700 19px/1 var(--serif); letter-spacing: .08em; }
.brand-name:lang(en), :lang(en) .brand-name { font: 400 22px/1 var(--serif-en); letter-spacing: 0; }
.brand-tag { font-size: 13px; line-height: 1; color: var(--ink-2); letter-spacing: .06em; padding-left: 12px; border-left: 1px solid var(--rule); }
.nav { display: flex; align-items: center; gap: clamp(14px, 2.6vw, 36px); font-size: 15px; }
.nav a { text-decoration: none; padding: 10px 0; position: relative; }
.nav a::after { content: ""; position: absolute; left: 0; right: 0; bottom: 4px; height: 2px; background: var(--red); transform: scaleX(0); transform-origin: left; transition: transform .35s var(--ease); }
.nav a:hover::after, .nav a[aria-current]::after { transform: scaleX(1); }
.nav a:hover { color: var(--ink); }
.nav .lang { font: 13px/1 var(--mono); letter-spacing: .06em; border: 1px solid var(--ink); padding: 8px 10px; border-radius: 99px; }
.nav .lang::after { display: none; }
.nav .lang:hover { background: var(--ink); color: var(--paper); }

/* ── the red thread ─────────────────────────────────── */
main { display: block; position: relative; flex: 1; }
@media (min-width: 761px) {
  main::before { content: ""; position: absolute; left: var(--thread-x); top: var(--thread-top, 0px); bottom: 0; width: 2px; margin-left: -1px; background: var(--red); transform-origin: top; transform: scaleY(var(--p, 1)); z-index: 3; pointer-events: none; }
  [data-node] { position: relative; }
  [data-node]::before { content: ""; position: absolute; z-index: 4; left: calc(var(--thread-x) - var(--inset) - 5px); top: var(--node-y, .9em); width: 10px; height: 10px; border-radius: 50%; background: var(--paper); box-shadow: inset 0 0 0 2px var(--red); }
  [data-node].lit::before, .no-js [data-node]::before { background: var(--red); }
}

/* ── home: hero ─────────────────────────────────────── */
.p-home { --hh: clamp(560px, calc(100svh - var(--top-h)), 66.667vw); }
.p-home main { --thread-top: calc(var(--hh) * .799); }
.hero { position: relative; }
.hero-frame { position: relative; margin-left: var(--inset); height: var(--hh); background: var(--wall); }
.hero-photo img, .hero-loop { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 100% 79.9%; }
.hero-loop { opacity: 0; transition: opacity 1.2s ease; }
.hero-loop.on { opacity: 1; }
.cable { position: absolute; top: 79.9%; left: calc(var(--thread-x) - var(--inset)); width: calc(var(--inset) - var(--thread-x) + 2px); height: 3px; margin-top: -1px; background: linear-gradient(90deg, var(--red), #9c2f1d); border-radius: 2px 0 0 2px; }
.hero-copy { position: absolute; z-index: 2; top: clamp(48px, 12%, 140px); left: calc(var(--inset) + clamp(24px, 5vw, 96px)); width: min(46vw, 660px); }
.display { font-size: clamp(44px, 5.5vw, 92px); line-height: 1.14; letter-spacing: .02em; }
.display:lang(en), :lang(en) .display { font-size: clamp(52px, 6.6vw, 112px); line-height: .98; letter-spacing: -.02em; }
.display .ln { display: block; }
.lede { margin-top: clamp(20px, 2.2vw, 32px); max-width: 30em; font-size: clamp(16px, 1.25vw, 19px); line-height: 1.8; color: var(--ink-2); }
.hero .lede { color: var(--ink); max-width: 27em; }
.cta { display: inline-flex; align-items: center; margin-top: clamp(24px, 2.6vw, 40px); padding: 16px 24px; background: var(--ink); color: var(--paper); text-decoration: none; font-weight: 700; font-size: 16px; letter-spacing: .04em; transition: background .3s; }
.cta:hover { color: var(--paper); background: var(--red-text); }
.motion-toggle { position: absolute; right: var(--gutter); bottom: 20px; z-index: 3; font: 12px/1 var(--mono); letter-spacing: .05em; padding: 9px 12px; background: rgb(235 229 218 / .82); color: var(--ink); border: 1px solid var(--rule); border-radius: 99px; cursor: pointer; }
.motion-toggle[aria-pressed="false"] .mt-on, .motion-toggle[aria-pressed="true"] .mt-off { display: none; }

@media (prefers-reduced-motion: no-preference) {
  .display .ln { animation: rise 1.1s var(--ease) both; }
  .display .ln + .ln { animation-delay: .12s; }
  .hero .lede, .hero .cta { animation: fade 1s .35s var(--ease) both; }
  .cable { animation: draw-x .9s .5s var(--ease) both; transform-origin: right; }
}
@keyframes rise { from { opacity: 0; transform: translateY(.45em); } }
@keyframes fade { from { opacity: 0; transform: translateY(10px); } }
@keyframes draw-x { from { transform: scaleX(0); } }

/* ── sections ───────────────────────────────────────── */
.chapters, .works, .page-head, .entry, .about, .contact, .policy, .lost { padding-inline: var(--inset); }
.chapters { padding-top: clamp(56px, 7vw, 104px); padding-bottom: clamp(24px, 3vw, 40px); }
.chapter { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: clamp(16px, 2vw, 32px); align-items: start; padding: clamp(28px, 3vw, 44px) 0 clamp(40px, 4.4vw, 64px); border-top: 1px solid var(--rule); --node-y: calc(clamp(28px, 3vw, 44px) + .55em); }
.chapter:last-child { border-bottom: 1px solid var(--rule); }
.chapter-no { grid-column: 1; font: 13px/2.4 var(--mono); color: var(--red-text); letter-spacing: .06em; }
.chapter-word { grid-column: 2 / span 2; font: 700 15px/2.2 var(--serif); letter-spacing: .14em; color: var(--ink-2); }
.chapter-word:lang(en), :lang(en) .chapter-word { font: 13px/2.4 var(--mono); text-transform: uppercase; letter-spacing: .1em; }
.chapter h2 { grid-column: 4 / span 5; font-size: clamp(30px, 3.3vw, 54px); line-height: 1.22; }
.chapter h2:lang(en), :lang(en) .chapter h2 { font-size: clamp(34px, 3.8vw, 60px); line-height: 1.05; }
.chapter-body { grid-column: 9 / span 4; padding-top: .5em; color: var(--ink-2); }
.chapter-body .link { margin-top: 18px; }

.link { display: inline-flex; align-items: center; font-weight: 700; font-size: 15px; letter-spacing: .03em; text-decoration: none; color: var(--ink); border-bottom: 1.5px solid var(--red); padding-bottom: 3px; }
.link:hover { color: var(--red-text); }

.works { padding-top: clamp(64px, 8vw, 128px); padding-bottom: clamp(80px, 10vw, 160px); }
.works-head { display: flex; align-items: baseline; justify-content: space-between; gap: 24px; padding-bottom: clamp(32px, 4vw, 56px); --node-y: .55em; }
.display-2 { font-size: clamp(40px, 6vw, 100px); line-height: 1.08; letter-spacing: .02em; }
.display-2:lang(en), :lang(en) .display-2 { font-size: clamp(46px, 7vw, 116px); line-height: .98; letter-spacing: -.02em; }

.work { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: clamp(16px, 2vw, 32px); align-items: end; }
.work + .work { margin-top: clamp(80px, 10vw, 160px); }
.work-photo, .entry-photo, .about-photo { margin: 0; }
.photo img { width: 100%; background: var(--wall); }
.work-muninn .work-photo { grid-column: 1 / span 8; }
.work-muninn .work-text { grid-column: 9 / span 4; padding-left: clamp(24px, 4vw, 64px); }
.work-no { font: 13px/1 var(--mono); letter-spacing: .08em; color: var(--red-text); margin-bottom: 18px; }
.work-kind { font: 13px/1.4 var(--mono); letter-spacing: .04em; color: var(--ink-2); margin-bottom: 10px; }
.work-title { display: flex; align-items: center; gap: 16px; margin-bottom: 18px; }
.app-icon { border-radius: 22%; box-shadow: 0 1px 0 rgb(0 0 0 / .08), 0 10px 24px -12px rgb(22 19 15 / .5); }
.work h3, .entry h2 { font-size: clamp(34px, 3.4vw, 56px); line-height: 1.1; }
.work h3:lang(en), :lang(en) .work h3 { font-size: clamp(38px, 3.8vw, 62px); }
.work-text > p:not([class]), .entry-text > p:not([class]) { color: var(--ink-2); margin-bottom: 22px; max-width: 34em; }
.work-text .link { margin-top: 4px; }

.work-models { align-items: center; }
.work-models .work-text, .entry-models .entry-text { grid-column: 1 / span 5; }
.work-models .work-figure, .entry-models .work-figure { grid-column: 7 / span 6; }
.stat { font: 700 clamp(56px, 7vw, 120px)/1 var(--serif); letter-spacing: -.01em; margin: 22px 0 22px; font-variant-numeric: lining-nums; }
.stat:lang(en), :lang(en) .stat { font: 400 clamp(64px, 8vw, 136px)/.9 var(--serif-en); }
.stat span { color: var(--red); }
.fine { font: 12.5px/1.6 var(--mono); color: var(--ink-2); letter-spacing: .02em; margin-bottom: 8px; }
.work-text .fine + .link { margin-top: 16px; }

.work-figure { position: relative; }
.work-photo, .entry-photo { position: relative; }
.device { margin: 0; background: #0d0c0a; padding: 2.4%; border-radius: 14% / 7%; box-shadow: 0 0 0 1px rgb(255 255 255 / .06) inset, 0 30px 60px -28px rgb(22 19 15 / .55), 0 12px 20px -14px rgb(22 19 15 / .4); }
.device-screen img { width: 100%; border-radius: 11.5% / 5.8%; }
.device-muninn { position: absolute; left: 5%; bottom: -14%; width: 24%; min-width: 120px; }
.peek { grid-column: 7 / span 6; height: clamp(300px, 30vw, 420px); overflow: hidden; background: var(--paper-2); border: 1px solid var(--rule); display: flex; justify-content: center; padding-top: clamp(28px, 3vw, 48px); }
.device-bps { width: clamp(200px, 19vw, 280px); align-self: flex-start; }
.quant { margin-top: -1px; background: var(--ink); color: var(--paper); padding: 22px 24px 18px; }
.quant-cols { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.quant-cols button { display: grid; justify-items: start; gap: 6px; padding: 10px 10px 12px; color: var(--paper); background: transparent; border: 1px solid rgb(235 229 218 / .22); border-radius: 4px; cursor: pointer; text-align: left; font: inherit; }
.quant-cols button:hover { border-color: rgb(235 229 218 / .6); }
.quant-cols button[aria-pressed="true"] { border-color: var(--red-on-ink); background: rgb(240 106 76 / .08); }
.q-stack { display: flex; flex-direction: column-reverse; gap: 3px; height: 94px; width: 100%; margin-bottom: 6px; }
.q-stack i { display: block; height: 2.5px; background: rgb(235 229 218 / .55); }
[aria-pressed="true"] .q-stack i { background: var(--red-on-ink); }
.q-name { font: 13px/1 var(--mono); letter-spacing: .05em; }
.q-bits { font: 11.5px/1 var(--mono); color: #b9b1a3; }
.quant-note { font: 11.5px/1.4 var(--mono); color: #b9b1a3; margin-top: 14px; }

.work-bps { padding-top: clamp(40px, 5vw, 64px); border-top: 1px solid var(--rule); align-items: start; }
.work-bps .work-text, .entry-bps .entry-text { grid-column: 1 / span 5; }
.work-bps h3 { font-size: clamp(28px, 2.6vw, 40px); }

/* own connection: the dark band */
.own { background: var(--ink); color: var(--paper); padding: clamp(88px, 11vw, 168px) var(--inset); --node-y: calc(clamp(88px, 11vw, 168px) + .5em); }
.own[data-node]::before { left: calc(var(--thread-x) - 5px); background: var(--ink); }
.own h2 { max-width: 12em; }
.own-text { max-width: 40em; margin-top: clamp(28px, 3vw, 44px); color: #d8d1c4; font-size: clamp(16px, 1.2vw, 18px); }
.own .link { color: var(--paper); margin-left: .3em; }
.own .link:hover { color: var(--red-on-ink); }
.route { list-style: none; margin: clamp(48px, 6vw, 88px) 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); position: relative; }
.route::before { content: ""; position: absolute; left: 0; right: 0; top: 5px; height: 2px; background: var(--red); }
.route li { position: relative; padding-top: 32px; font: 400 clamp(22px, 2.4vw, 36px)/1.1 var(--serif-en); }
.route li:lang(zh-Hant), :lang(zh-Hant) .route li { font-family: var(--serif); font-weight: 700; font-size: clamp(20px, 2vw, 30px); }
.route li::before { content: ""; position: absolute; left: 0; top: 0; width: 12px; height: 12px; border-radius: 50%; background: var(--ink); box-shadow: inset 0 0 0 2px var(--red-on-ink); }
.route li:last-child::before { background: var(--red-on-ink); }
.route-k { display: block; font: 12px/1 var(--mono); color: var(--red-on-ink); letter-spacing: .08em; margin-bottom: 12px; }
.entry .route { margin: 28px 0 30px; }
.entry .route li { font-size: clamp(18px, 1.6vw, 24px); }
.entry .route li::before { background: var(--paper); box-shadow: inset 0 0 0 2px var(--red); }
.entry .route li:last-child::before { background: var(--red); }
.entry .route-k { color: var(--red-text); }

/* ── footer ─────────────────────────────────────────── */
.foot { background: var(--paper-2); border-top: 1px solid var(--rule); padding: 48px var(--inset) 56px; font-size: 14px; color: var(--ink-2); position: relative; z-index: 4; }
.foot-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1.6fr; gap: 24px 32px; align-items: start; }
.foot-co { display: flex; gap: 14px; align-items: flex-start; }
.foot-co p { display: grid; gap: 2px; color: var(--ink); }
.foot-co span:first-child { font: 700 16px/1.5 var(--serif); }
.foot-co span:last-child { font-size: 13px; color: var(--ink-2); }
.foot-id { font: 13px/1.7 var(--mono); white-space: nowrap; }
.foot-mail a { color: var(--ink); }
.foot-links { display: flex; flex-wrap: wrap; gap: 6px 22px; justify-content: flex-end; }
.foot-links a { color: var(--ink-2); text-decoration: none; }
.foot-links a:hover { color: var(--red-text); text-decoration: underline; }

/* ── inner pages ────────────────────────────────────── */
.page-head { padding-top: clamp(64px, 9vw, 150px); padding-bottom: clamp(48px, 6vw, 96px); --node-y: .55em; }
.page-head h1 { max-width: 13em; }
.page-head .lede { max-width: 36em; }
.toc-inline { display: flex; flex-wrap: wrap; gap: 10px; margin-top: clamp(32px, 4vw, 56px); }
.toc-inline a { display: inline-flex; gap: 10px; align-items: baseline; padding: 10px 16px; border: 1px solid var(--ink); border-radius: 99px; text-decoration: none; font-size: 15px; }
.toc-inline a:hover { background: var(--ink); color: var(--paper); }
.toc-inline span { font: 12px/1 var(--mono); color: var(--red-text); }
.toc-inline a:hover span { color: var(--red-on-ink); }

.entry { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: clamp(16px, 2vw, 32px); padding-top: clamp(56px, 6vw, 96px); padding-bottom: clamp(72px, 9vw, 140px); border-top: 1px solid var(--rule); margin-inline: 0; --node-y: calc(clamp(56px, 6vw, 96px) + 6px); scroll-margin-top: 12px; }
.entry[data-node]::before { left: calc(var(--thread-x) - 5px); }
.entry-muninn .entry-photo { grid-column: 1 / span 7; align-self: start; position: sticky; top: 24px; }
.entry-muninn .entry-text { grid-column: 8 / span 5; padding-left: clamp(0px, 2vw, 32px); }
.entry-models { align-items: start; }
.entry-models .work-figure { position: sticky; top: 24px; }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 26px; margin-top: 28px; }
.button { display: inline-flex; align-items: center; padding: 15px 22px; background: var(--ink); color: var(--paper); text-decoration: none; font-weight: 700; font-size: 15px; letter-spacing: .03em; transition: background .3s; }
.button:hover { background: var(--red-text); color: var(--paper); }
.button-quiet { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--ink); }
.button-quiet:hover { background: var(--ink); color: var(--paper); }
.model-list { list-style: none; margin: 26px 0 0; padding: 0; border-top: 1px solid var(--rule); }
.model-list li { border-bottom: 1px solid var(--rule); }
.model-list a { display: flex; justify-content: space-between; gap: 12px; padding: 14px 0; font: 13.5px/1.4 var(--mono); text-decoration: none; overflow-wrap: anywhere; }
.entry-bps { padding-bottom: clamp(96px, 11vw, 168px); }
.entry-bps h2 { font-size: clamp(30px, 2.8vw, 44px); margin-bottom: 18px; }
.entry-bps .entry-text > p:not([class]) { margin-bottom: 0; }

.about { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: clamp(16px, 2vw, 32px); padding-bottom: clamp(96px, 11vw, 168px); align-items: start; }
.about .page-head { grid-column: 1 / span 7; padding-inline: 0; }
.about-photo { grid-column: 8 / span 5; grid-row: 1 / span 2; margin-top: clamp(64px, 9vw, 150px); }
.facts { grid-column: 1 / span 7; margin: 0; border-top: 1.5px solid var(--ink); --node-y: 34px; }
.facts div { display: grid; grid-template-columns: 10em 1fr; gap: 24px; padding: 26px 0 28px; border-bottom: 1px solid var(--rule); align-items: baseline; }
.facts dt { font: 13px/1.4 var(--mono); color: var(--ink-2); letter-spacing: .04em; }
.facts dd { margin: 0; font: 700 clamp(26px, 2.8vw, 44px)/1.2 var(--serif); letter-spacing: .04em; }
.facts dd:lang(en) { font: 400 clamp(30px, 3.2vw, 50px)/1.1 var(--serif-en); letter-spacing: 0; }

.contact { padding-bottom: 0; }
.contact .page-head { padding-inline: 0; }
.mail { --node-y: .62em; border-top: 1.5px solid var(--ink); padding-top: clamp(32px, 4vw, 56px); }
.mail a { font: 400 clamp(44px, 9.5vw, 168px)/1 var(--serif-en); letter-spacing: -.02em; text-decoration: none; background: linear-gradient(var(--red), var(--red)) 0 100% / 100% 3px no-repeat; padding-bottom: .08em; overflow-wrap: anywhere; transition: color .3s, background-size .5s var(--ease); }
.contact-photo { margin: clamp(56px, 7vw, 112px) 0 0 calc(var(--inset) * -1 + var(--thread-x)); }
.contact-photo img { width: 100%; }
.mail a:hover { color: var(--red-text); background-size: 0 3px; background-position: 100% 100%; }

.policy { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: clamp(16px, 2vw, 32px); padding-bottom: clamp(96px, 11vw, 168px); border-top: 1px solid var(--rule); padding-top: clamp(40px, 5vw, 72px); }
.policy-index { grid-column: 1 / span 3; position: sticky; top: 24px; align-self: start; font-size: 14px; }
.policy-index p { font: 12px/1 var(--mono); letter-spacing: .08em; color: var(--red-text); margin-bottom: 16px; }
.policy-index ol { list-style: none; margin: 0; padding: 0; counter-reset: s; border-top: 1px solid var(--rule); }
.policy-index li { counter-increment: s; border-bottom: 1px solid var(--rule); }
.policy-index a { display: flex; gap: 12px; padding: 11px 0; text-decoration: none; color: var(--ink-2); line-height: 1.45; }
.policy-index a::before { content: counter(s, decimal-leading-zero); font: 11.5px/1.9 var(--mono); color: var(--ink-3); }
.policy-index a:hover { color: var(--red-text); }
.prose { grid-column: 5 / span 7; max-width: 40em; }
.prose > p:first-child { font: 13.5px/1.7 var(--mono); color: var(--ink-2); padding-bottom: 28px; border-bottom: 1px solid var(--rule); }
.prose h2 { font-size: clamp(24px, 2.2vw, 32px); line-height: 1.3; margin: 56px 0 18px; scroll-margin-top: 24px; }
.prose h2:lang(en), :lang(en) .prose h2 { font-size: clamp(28px, 2.6vw, 38px); }
.prose p { margin: 0 0 18px; color: var(--ink); }
.prose p:lang(zh-Hant), :lang(zh-Hant) .prose p { line-height: 1.95; text-align: justify; }
.prose a { color: var(--red-text); }
.flow { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin: 28px 0 32px; padding: 20px; background: var(--paper-2); border-left: 2px solid var(--red); font: 13px/1.5 var(--mono); }
.flow span { padding: 6px 10px; background: var(--paper); border: 1px solid var(--rule); }
.flow b { color: var(--red-text); font-weight: 400; }

.lost { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: clamp(16px, 2vw, 32px); align-items: center; padding-top: clamp(32px, 4vw, 64px); padding-bottom: clamp(96px, 10vw, 160px); }
.lost-photo { grid-column: 1 / span 7; }
.lost-text { grid-column: 9 / span 4; }
.lost-text h1 { white-space: nowrap; font-size: clamp(40px, 4.6vw, 76px); }
.lost-links { display: flex; flex-wrap: wrap; gap: 14px 28px; margin-top: 32px; }

/* scroll-linked reveals where the browser supports them */
@media (prefers-reduced-motion: no-preference) {
  @supports (animation-timeline: view()) {
    .work-photo img, .entry-photo img, .photo-paper img, .about-photo img { animation: unveil linear both; animation-timeline: view(); animation-range: entry 0% cover 40%; }
    .chapter h2, .works-head h2, .own h2 { animation: lift linear both; animation-timeline: view(); animation-range: entry 0% entry 80%; }
    .route::before { animation: draw-x linear both; animation-timeline: view(); animation-range: entry 10% cover 45%; transform-origin: left; }
  }
}
@keyframes unveil { from { clip-path: inset(14% 0 0 0); transform: scale(1.04); } to { clip-path: inset(0); transform: none; } }
@keyframes lift { from { transform: translateY(28px); } }

@media (min-width: 1101px) {
  .chapters { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); column-gap: clamp(24px, 3vw, 56px); }
  .chapter { display: block; border-bottom: 1px solid var(--rule); padding: 28px 0 40px; --node-y: 34px; }
  .chapter + .chapter[data-node]::before { display: none; }
  .chapter-no, .chapter-word { display: inline-block; margin-right: 14px; }
  .chapter h2 { margin: 18px 0 14px; font-size: clamp(26px, 2.3vw, 36px); }
  .chapter h2:lang(en), :lang(en) .chapter h2 { font-size: clamp(30px, 2.6vw, 40px); }
  .chapter-body { padding-top: 0; }
}

/* ── responsive ─────────────────────────────────────── */
@media (max-width: 1100px) {
  .brand-tag { display: none; }
  .chapter h2 { grid-column: 3 / span 6; }
  .chapter-word { grid-column: 2 / span 1; }
  .work-muninn .work-text { grid-column: 8 / span 5; }
  .foot-grid { grid-template-columns: 1fr 1fr; }
  .foot-links { justify-content: flex-start; }
}

@media (max-width: 760px) {
  :root { --top-h: 64px; --gutter: 20px; }
  body { font-size: 16px; }
  .seal { width: 30px; height: 30px; }
  .brand { gap: 10px; }
  .brand-name { font-size: 17px; }
  .nav { gap: 16px; font-size: 15px; }
  .nav .lang { padding: 7px 9px; font-size: 12px; }

  .p-home { --hh: auto; }
  .hero { display: flex; flex-direction: column-reverse; }
  .hero-frame { margin-left: 0; height: auto; aspect-ratio: 836 / 1024; max-height: 78svh; width: 100%; }
  .cable, .motion-toggle { display: none; }
  .hero-copy { position: static; width: auto; padding: 20px var(--gutter) 36px; }
  .display { font-size: clamp(32px, 10.2vw, 56px); }
  .display:lang(en), :lang(en) .display { font-size: clamp(42px, 12.6vw, 60px); }
  .cta { width: 100%; justify-content: space-between; }

  .chapters { padding-top: 48px; }
  .chapter { padding: 22px 0 28px; }
  .chapter h2 { font-size: 24px; }
  .chapter h2:lang(en), :lang(en) .chapter h2 { font-size: 28px; }
  .chapter-body { font-size: 15px; }
  .chapter { grid-template-columns: auto 1fr; column-gap: 14px; row-gap: 10px; }
  .chapter-no { grid-column: 1; }
  .chapter-word { grid-column: 2; }
  .chapter h2, .chapter-body { grid-column: 1 / -1; }
  .chapter-body { padding-top: 4px; }
  .works-head { flex-direction: column; gap: 14px; }
  .work, .entry, .about, .policy, .lost { grid-template-columns: minmax(0, 1fr); row-gap: 28px; }
  .work > *, .entry > *, .about > *, .policy > *, .lost > * { grid-column: 1 / -1 !important; }
  .entry-photo, .entry-models .work-figure, .policy-index { position: static; }
  .work-muninn .work-text, .entry-muninn .entry-text { padding-left: 0; }
  .about-photo { grid-row: auto; margin-top: 0; }
  .device-muninn { width: 30%; bottom: -16%; }
  .work-muninn .work-text, .entry-muninn .entry-text { margin-top: 15%; }
  .peek { height: 340px; }
  .device-bps { width: 200px; }
  .contact-photo { margin-left: calc(var(--gutter) * -1); margin-right: calc(var(--gutter) * -1); }
  .facts div { grid-template-columns: 1fr; gap: 6px; }
  .quant { padding: 16px; }
  .quant-cols { gap: 8px; }
  .q-stack { height: 70px; gap: 2px; }
      .route li { font-size: 19px; padding-top: 28px; }
  .entry .route li { font-size: 17px; }
  .foot-grid { grid-template-columns: 1fr; }
  .policy-index { margin-bottom: 8px; }
  .prose h2 { margin-top: 44px; }
  .flow { flex-direction: column; align-items: flex-start; }
  .flow b { transform: rotate(90deg); margin-left: 10px; }
  .about .facts { order: 2; }
  .about-photo { order: 3; }
}
@media (max-width: 520px) {
  .top { height: auto; flex-wrap: wrap; row-gap: 0; padding-top: 14px; }
  .nav { width: 100%; gap: 22px; margin-top: 12px; border-top: 1px solid var(--rule); }
  .nav a { padding: 12px 0; }
  .nav .lang { margin-left: auto; padding: 6px 10px; }
  .p-home .top { border-bottom: 0; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .hero-loop { display: none; }
}
