/* K-series shared layer: theme tokens (each kNN.css overrides), scroll-animated sections,
   project page. Every section reacts to scroll through --p (0→1 as it crosses the viewport). */
:root { --bg: #0E1014; --ink: #ECEEF2; --ink-2: #8A90A0; --line: rgba(236,238,242,.14); --panel: #1A1D24; --acc: #F6C27A; --glow: #FFE6B8;
  --display: "Instrument Serif", Georgia, serif; --text: "Geist", "Helvetica Neue", Arial, sans-serif; --mono: "Geist Mono", ui-monospace, monospace; color-scheme: dark; }
body.k { background: var(--bg); color: var(--ink); font-family: var(--text); font-size: 15px; overflow-x: hidden; }
.mono { font-family: var(--mono); font-size: 10px; letter-spacing: .05em; text-transform: uppercase; color: var(--ink-2); }
.k-top { position: fixed; z-index: 70; top: 0; left: 0; right: 0; display: grid; grid-template-columns: 1fr auto 1fr; gap: 12px; align-items: baseline; padding: 16px var(--gr) 0 var(--gl); font-size: 13px; mix-blend-mode: difference; color: #fff; }
.k-top nav { display: flex; gap: 18px; } .k-top nav a:hover { font-family: var(--display); font-style: italic; }
.k-top .mono { justify-self: end; color: #fff; }
.k-prog { position: fixed; z-index: 71; left: 0; top: 0; height: 2px; width: 100%; background: var(--acc); transform-origin: left; transform: scaleX(var(--sp, 0)); box-shadow: 0 0 12px var(--glow); }
.kswitch { position: fixed; z-index: 400; right: 10px; bottom: 10px; display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 3px; max-width: 290px; font-family: var(--mono); font-size: 9px; }
.kswitch a { padding: 3px 5px; background: rgba(128,128,128,.25); color: var(--ink); backdrop-filter: blur(6px); } .kswitch a.is-on, .kswitch a:hover { background: var(--acc); color: #000; }

/* loader shell */
.loader { position: fixed; inset: 0; z-index: 300; background: var(--bg); display: grid; place-items: center; transition: opacity .9s var(--ease), transform 1.1s var(--ease); overflow: hidden; }
.loader.is-done { opacity: 0; pointer-events: none; transform: scale(1.04); }
.loader canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.ld-hook { position: relative; z-index: 2; text-align: center; display: grid; gap: 10px; }
.ld-hook b { font-family: var(--display); font-weight: 400; font-size: clamp(40px, 6vw, 96px); line-height: .95; }
.ld-hook b em { font-style: italic; }

/* hero shell */
.k-hero { position: relative; height: 100svh; min-height: 640px; overflow: hidden; }
.k-hero > canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.k-ctype { position: absolute; z-index: 5; left: var(--gl); bottom: 34px; font-size: clamp(22px, 2.1vw, 32px); line-height: 1.08; }
.k-ctype p { margin: 0; } .k-ctype .c2 { padding-left: .95em; } .k-ctype .c3 { display: flex; gap: 1.4em; align-items: baseline; } .k-ctype .by { font-family: var(--display); font-style: italic; font-size: .6em; } .k-ctype .name { font-family: var(--display); font-style: italic; }
.k-intro { position: absolute; z-index: 5; right: var(--gr); bottom: 34px; width: min(340px, 30vw); margin: 0; font-size: 14px; line-height: 1.5; text-align: right; }
.k-intro b { display: block; font-family: var(--display); font-weight: 400; font-size: 22px; line-height: 1.15; margin-bottom: 6px; }
.k-scrollcue { position: absolute; z-index: 5; left: 50%; bottom: 26px; translate: -50% 0; display: grid; justify-items: center; gap: 6px; }
.k-scrollcue i { width: 1px; height: 40px; background: linear-gradient(var(--acc), transparent); animation: cue 1.8s ease-in-out infinite; }
@keyframes cue { 0% { transform: scaleY(0); transform-origin: top; } 50% { transform: scaleY(1); transform-origin: top; } 51% { transform-origin: bottom; } 100% { transform: scaleY(0); transform-origin: bottom; } }

/* scroll-animated text */
[data-split] .w { display: inline-block; overflow: hidden; vertical-align: top; }
[data-split] .w > span { display: inline-block; transform: translateY(105%); transition: transform 1s var(--out); transition-delay: calc(var(--i) * 28ms); }
[data-split].is-in .w > span { transform: none; }
.k-band { height: 1px; background: linear-gradient(90deg, transparent, var(--acc), var(--glow), transparent); transform: scaleX(var(--p, 0)); box-shadow: 0 0 14px var(--glow); }

/* shared sections */
.k-sec { position: relative; z-index: 2; padding: clamp(110px, 13vw, 190px) var(--gr) 0 var(--gl); }
.k-h { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: var(--gap); align-items: end; margin-bottom: 50px; }
.k-h .mono { grid-column: span 3; }
.k-h h2 { grid-column: span 6; margin: 0; font-family: var(--display); font-weight: 400; font-size: clamp(40px, 5vw, 86px); line-height: .95; }
.k-h h2 em { font-style: italic; color: var(--acc); }
.k-h p { grid-column: span 3; margin: 0; color: var(--ink-2); font-size: 14px; }
.k-h .k-band { grid-column: 1 / -1; margin-top: 16px; }
.k-list { list-style: none; margin: 0; padding: 0; }
.k-list a { position: relative; display: grid; grid-template-columns: 60px minmax(0, 2.4fr) minmax(0, 2fr) minmax(0, 1fr) 60px; gap: var(--gap); align-items: baseline; padding: 16px 0; border-top: 1px solid var(--line); overflow: hidden; transform: translateX(calc((1 - var(--p, 1)) * -40px)); opacity: calc(.2 + var(--p, 1) * .8); }
.k-list a::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: linear-gradient(90deg, var(--acc), transparent); transform: scaleX(0); transform-origin: left; transition: transform .7s var(--out); }
.k-list a:hover::after { transform: none; }
.k-list b { font-family: var(--display); font-weight: 400; font-size: clamp(28px, 3vw, 48px); line-height: 1; }
.k-list a:hover b { font-style: italic; color: var(--acc); }
.k-list .d { color: var(--ink-2); }
.k-about { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: var(--gap); }
.k-face { grid-column: span 4; margin: 0; overflow: hidden; aspect-ratio: 4 / 5; clip-path: inset(calc((1 - var(--p, 1)) * 30%) 0 0 0); }
.k-face img { width: 100%; height: 100%; object-fit: cover; transform: scale(calc(1.25 - var(--p, 1) * .25)); filter: grayscale(.4); }
.k-atxt { grid-column: 6 / -1; }
.k-atxt .lead { margin: 0 0 20px; font-family: var(--display); font-size: clamp(26px, 2.8vw, 42px); line-height: 1.12; }
.k-atxt > p { color: var(--ink-2); max-width: 58ch; }
.k-cv { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 26px; margin-top: 26px; }
.k-cv div { display: grid; grid-template-columns: 120px minmax(0, 1fr); gap: 10px; padding: 9px 0; border-top: 1px solid var(--line); font-size: 13px; }
.k-cv b { display: block; font-weight: 500; }
.k-stats { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--gap); margin-top: 60px; }
.k-stats div { border-top: 1px solid var(--ink); padding-top: 10px; }
.k-stats b { display: block; font-family: var(--display); font-weight: 400; font-size: clamp(50px, 6vw, 100px); line-height: .9; color: var(--acc); }
.k-contact { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: var(--gap); padding-bottom: 80px; }
.k-mail { grid-column: 1 / -1; font-family: var(--display); font-size: clamp(42px, 7.4vw, 140px); line-height: .9; overflow-wrap: anywhere; } .k-mail:hover { font-style: italic; color: var(--acc); text-shadow: 0 0 30px var(--glow); }
.k-map { grid-column: span 6; position: relative; aspect-ratio: 16 / 9; margin-top: 30px; } .k-map .ct-map { position: absolute; inset: 0; aspect-ratio: auto; border: 1px solid var(--line); background: var(--panel); }
.k-cinfo { grid-column: 8 / -1; margin: 30px 0 0; display: grid; grid-template-columns: 110px 1fr; gap: 10px 16px; } .k-cinfo dt { font-family: var(--mono); font-size: 10px; text-transform: uppercase; color: var(--ink-2); padding-top: 4px; } .k-cinfo dd { margin: 0; } .k-cinfo a { border-bottom: 1px solid currentColor; }
.k-foot { position: relative; z-index: 2; display: flex; justify-content: space-between; padding: 14px var(--gr) 24px var(--gl); border-top: 1px solid var(--line); }
body.k .m-minor path { stroke: color-mix(in srgb, var(--ink) 18%, transparent); } body.k .m-major path { stroke: color-mix(in srgb, var(--ink) 35%, transparent); } body.k .m-label text { fill: var(--ink-2); } body.k .m-pin path { fill: var(--acc); } body.k .m-park path { fill: color-mix(in srgb, var(--acc) 12%, transparent); } body.k .map-zoom { background: var(--panel); color: var(--ink); }

/* project page with scroll motion */
.project.kp { background: var(--bg); color: var(--ink); }
.kp-bar { position: sticky; top: 0; z-index: 4; display: grid; grid-template-columns: 1fr auto 1fr; padding: 16px var(--gr) 14px var(--gl); background: linear-gradient(var(--bg) 60%, transparent); font-size: 13px; } .kp-bar a { justify-self: end; }
.kp-hero { position: relative; height: 92svh; overflow: hidden; margin-top: -50px; }
.kp-hero img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transform: scale(calc(1 + var(--q, 0) * .25)); filter: brightness(calc(1 - var(--q, 0) * .5)); }
.kp-hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 40%, var(--bg)); }
.kp-title { position: absolute; z-index: 2; left: var(--gl); right: var(--gr); bottom: 40px; transform: translateY(calc(var(--q, 0) * -80px)); }
.kp-title h1 { margin: 0; font-family: var(--display); font-weight: 400; font-size: clamp(56px, 9vw, 170px); line-height: .85; text-shadow: 0 0 40px rgba(0,0,0,.25); }
.kp-title p { margin: 10px 0 0; font-family: var(--display); font-style: italic; font-size: clamp(20px, 2vw, 30px); }
.kp-body { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: var(--gap); padding: 60px var(--gr) 70px var(--gl); }
.kp-lead { grid-column: 1 / span 7; margin: 0; font-family: var(--display); font-size: clamp(26px, 2.8vw, 44px); line-height: 1.12; }
.kp-txt { grid-column: 1 / span 7; } .kp-txt p { color: var(--ink-2); max-width: 64ch; }
.kp-spec { grid-column: 9 / -1; grid-row: 1 / span 2; display: grid; gap: 10px; align-content: start; font-size: 13px; }
.kp-spec div { border-top: 1px solid var(--line); padding-top: 6px; } .kp-spec b { display: block; font-family: var(--mono); font-weight: 400; font-size: 9px; text-transform: uppercase; color: var(--ink-2); }
.project.kp .gal figure { background: var(--panel); transform: translateY(calc((1 - var(--p, 1)) * 60px)) scale(calc(.94 + var(--p, 1) * .06)); opacity: calc(.15 + var(--p, 1) * .85); }
.project.kp .g-text h3 { font-family: var(--display); color: var(--acc); color: color-mix(in oklab, var(--pc, var(--acc)), #141516 var(--pdk, 22%)); }
.kp-next { display: block; position: relative; overflow: hidden; margin-top: 120px; padding: 60px var(--gr) 100px var(--gl); border-top: 1px solid var(--line); }
.kp-next b { display: block; font-family: var(--display); font-weight: 400; font-size: clamp(56px, 9vw, 170px); line-height: .85; transition: transform .8s var(--out); } .kp-next:hover b { transform: translateX(2vw); font-style: italic; color: var(--acc); }
.kp-next .k-band { margin-top: 20px; transform: scaleX(1); }

@media (max-width: 900px) {
  .k-intro { display: none; } .k-h .mono, .k-h h2, .k-h p, .k-face, .k-atxt, .k-map, .k-cinfo, .kp-lead, .kp-txt, .kp-spec { grid-column: 1 / -1; grid-row: auto; }
  .k-list a { grid-template-columns: 40px minmax(0, 1fr) 50px; } .k-list a > :nth-child(3), .k-list a > :nth-child(4) { display: none; } .k-cv { grid-template-columns: minmax(0, 1fr); } .k-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (prefers-reduced-motion: reduce) { [data-split] .w > span { transform: none; } }

/* Showcase rule: artwork is never cropped and always centred in its frame. */
.k-shot { position: relative; margin: 0; display: grid; place-items: center; overflow: hidden; background: radial-gradient(70% 70% at 50% 50%, color-mix(in srgb, var(--pc, var(--acc)) 22%, transparent), transparent 75%), var(--panel); }
.k-shot { box-sizing: border-box; }
.k-shot img, .k-shot video { display: block; width: 100%; height: 100%; min-height: 0; object-fit: contain; object-position: 50% 50%; }
.kp-hero { background: radial-gradient(60% 60% at 50% 45%, color-mix(in srgb, var(--pc) 55%, transparent), transparent 75%), var(--bg); }
.kp-hero img { inset: 70px var(--gr) 30% var(--gl); width: calc(100% - var(--gl) - var(--gr)); height: auto; max-height: calc(70% - 70px); margin: 0 auto; object-fit: contain; object-position: 50% 50%; transform: scale(calc(1 + var(--q, 0) * .06)); }
[data-split] .w { padding: .1em 0 .05em; margin: -.1em 0 -.05em; }
.kp-title h1 { text-shadow: none; } .kp-title > .mono { display: block; margin-bottom: 12px; }
