/* Layout: light-weight gothic. The top page (About me + index) is indigo; each case has its own page in its own colour. KV and single films run edge to edge, everything else sits inside the side margin. */
:root{
  --base-bg:#1b4266; --base-fg:#ffffff;
  --side:max(16px,4vw);
  --font:"Inter Tight","Zen Kaku Gothic New","Hiragino Sans",sans-serif;
  --mono:"IBM Plex Mono",ui-monospace,Menlo,monospace;
  --ease:cubic-bezier(.2,.7,.2,1);
}
:root{color-scheme:dark}
*{box-sizing:border-box}
body{
  --bg:var(--base-bg); --fg:var(--base-fg);
  --muted:color-mix(in srgb,var(--fg) 62%,transparent);
  --line:color-mix(in srgb,var(--fg) 24%,transparent);
  --tag:color-mix(in srgb,var(--fg) 8%,transparent);
  margin:0;background:var(--bg);color:var(--fg);font-family:var(--font);font-weight:300;font-size:15px;line-height:1.9;letter-spacing:.02em;
  transition:background-color .9s var(--ease),color .9s var(--ease);
  -webkit-font-smoothing:antialiased;
}
a{color:inherit;text-underline-offset:3px}
a:focus-visible,button:focus-visible{outline:1px solid var(--fg);outline-offset:3px}
.label{font-family:var(--mono);font-weight:300;font-size:11px;letter-spacing:.1em;text-transform:uppercase;color:var(--muted)}
p{margin:0}

/* Top */
.top{min-height:100svh;padding:var(--side);display:flex;flex-direction:column;justify-content:center;align-items:flex-start;text-align:left;gap:6px}
.top h1{margin:0;font-weight:200;font-size:clamp(20px,2vw,30px);line-height:1.2;letter-spacing:.04em}
/* About me: label | role + text | profile. Small, airy type on one line rhythm (28px): the text and the profile start on the same line, the label sits on the role line */
.about{--lh:28px;--role:clamp(15px,1.2vw,18px);padding:0 var(--side) clamp(120px,14vw,200px);display:grid;grid-template-columns:minmax(max-content,2.6fr) minmax(0,4.6fr) minmax(0,5fr);grid-template-areas:"title role ." ". lead profile";column-gap:clamp(40px,7vw,128px);align-items:start}
/* "About me" title: right edge sits on the vertical axis, everything else starts to its right. Rises out of a mask when the section scrolls in, then the role, text and profile follow one by one */
.about-title{grid-area:title;margin:0;text-align:right;align-self:baseline;white-space:nowrap;font-size:clamp(22px,2vw,30px);font-weight:100;line-height:1;letter-spacing:.01em;overflow:hidden;padding-bottom:.06em}
.about-title span{display:inline-block}
.about[data-reveal] .about-title span{transform:translateY(105%);transition:transform 1.2s var(--ease)}
.about[data-reveal] .role,.about[data-reveal] .lead,.about[data-reveal] .profile{opacity:0;transform:translateY(24px);transition:opacity 1s var(--ease),transform 1s var(--ease)}
.about[data-reveal].in .about-title span,.about[data-reveal].in .role,.about[data-reveal].in .lead,.about[data-reveal].in .profile{opacity:1;transform:none}
.about[data-reveal].in .role{transition-delay:.35s}
.about[data-reveal].in .lead{transition-delay:.5s}
.about[data-reveal].in .profile{transition-delay:.65s}
.about .role{grid-area:role;align-self:baseline;margin:0 0 clamp(20px,2.2vw,32px);font-size:var(--role);font-weight:300;line-height:1.4;letter-spacing:.06em}
.about .lead{grid-area:lead;font-size:13px;line-height:var(--lh);letter-spacing:.05em;text-align:justify;max-width:31em}
.about .profile{grid-area:profile;grid-template-columns:120px 1fr;gap:10px 16px;font-size:12.5px;letter-spacing:.04em}
.about .profile dt,.about .profile dd{line-height:var(--lh);padding-top:0}
.about .profile .nb{display:inline-block}
dl.meta{display:grid;grid-template-columns:120px 1fr;gap:6px 16px;margin:0;font-size:13px}
dl.meta dt{font-family:var(--mono);font-weight:300;font-size:11px;letter-spacing:.1em;text-transform:uppercase;color:var(--muted);padding-top:3px}
dl.meta dd{margin:0;min-width:0}
.mine{font-weight:400}

/* Index */
nav{padding:0 var(--side) clamp(120px,16vw,240px)}
nav > .label{display:block;margin-bottom:12px}
.index{list-style:none;margin:0;padding:0;border-top:1px solid var(--line)}
.index li{border-bottom:1px solid var(--line)}
.index a{position:relative;isolation:isolate;overflow:hidden;display:grid;grid-template-columns:1fr auto;gap:16px;padding:22px 12px;margin:0 -12px;text-decoration:none;align-items:baseline;transition:background-color .35s var(--ease),color .35s var(--ease),padding .45s var(--ease)}
.index .t{font-weight:200;font-size:clamp(22px,2.8vw,42px);line-height:1.2;letter-spacing:0}
/* faint KV on the right of each row, fading out toward the title */
.index a::before{content:"";position:absolute;inset:0 0 0 auto;width:48%;z-index:-1;background:var(--img) center/cover no-repeat;opacity:.22;-webkit-mask-image:linear-gradient(to right,transparent,#000 70%);mask-image:linear-gradient(to right,transparent,#000 70%);transition:opacity .45s var(--ease),width .6s var(--ease)}
.index .r{font-size:12px;color:var(--muted);text-align:right}
@media (hover:hover){
  .index a:hover{background:var(--c);color:var(--cf);padding-left:28px}
  .index a:hover .r{color:inherit}
  .index a:hover::before{opacity:.55;width:56%}
}

/* Case */
article{display:flex;flex-direction:column;gap:24px;padding-bottom:clamp(140px,18vw,280px);scroll-margin-top:0}
article > *:not(.hero):not(.film){margin-inline:var(--side)}
.hero{margin:0 0 clamp(24px,4vw,56px)}
.hero img{width:100%;height:auto;display:block;background:var(--tag)}
h2{font-weight:200;font-size:clamp(36px,6vw,104px);line-height:1.05;letter-spacing:-.01em;margin:0;text-wrap:balance}
article > p:not(.result){font-size:16px}
.film{margin:clamp(24px,4vw,56px) 0;display:flex;flex-direction:column;gap:8px}
.film video{width:100%;aspect-ratio:16/9;max-height:100svh;display:block;background:#000}
.film figcaption{padding-inline:var(--side)}
.result{font-size:15px;font-weight:300;line-height:1.95;letter-spacing:.03em;border-left:1px solid var(--line);padding-left:16px}  /* outcomes: same scale as the body text, set apart only by a faint rule */

/* Slider (films) */
.slider{display:flex;flex-direction:column;gap:12px}
.track{display:flex;gap:12px;overflow-x:auto;scroll-snap-type:x mandatory;scrollbar-width:none;overscroll-behavior-x:contain}
.track::-webkit-scrollbar{display:none}
.track figure{flex:0 0 86%;margin:0;display:flex;flex-direction:column;gap:6px;scroll-snap-align:start;min-width:0;transition:opacity .4s}
.track figure:not(.on){opacity:.4}
.track video,.track img.fit{width:100%;aspect-ratio:16/9;display:block;background:#000}
.track img.fit{object-fit:contain}
.ctrl{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap}
.tabs{display:flex;gap:6px;flex-wrap:wrap}
.tab{font:inherit;font-size:12px;background:none;color:var(--muted);border:1px solid var(--line);padding:6px 12px;cursor:pointer;display:flex;gap:8px;align-items:baseline;transition:background-color .3s,color .3s}
.tab .num{font-family:var(--mono);font-size:11px}
.tab[aria-selected="true"]{color:var(--bg);background:var(--fg);border-color:var(--fg)}
.arrows{display:flex;gap:6px}
.arrows button{font:inherit;font-family:var(--mono);background:none;color:var(--fg);border:1px solid var(--line);width:40px;height:32px;cursor:pointer}
.arrows button:hover,.tab:hover{border-color:var(--fg)}
.arrows button:disabled{opacity:.3;cursor:default}

/* Gallery (photos) */
.gal{display:flex;flex-direction:column;gap:8px;min-width:0}
.gal-view{position:relative;flex:1;min-height:0}
.gal-track{position:absolute;inset:0;display:flex;gap:8px;overflow-x:auto;scroll-snap-type:x mandatory;scrollbar-width:none;overscroll-behavior-x:contain}
.gal-track::-webkit-scrollbar{display:none}
.gal-track figure{margin:0;height:100%;flex:0 0 auto;aspect-ratio:2/3;scroll-snap-align:start}
.gal-track img{width:100%;height:100%;object-fit:cover;display:block;background:var(--tag)}
.gal-ctrl{display:flex;justify-content:space-between;align-items:center;gap:8px}
.gal-tall .gal-view{flex:none;height:min(42vw,640px)}
.gal-wide .gal-view{flex:none;aspect-ratio:2.3/1;max-width:100%}
.gal-wide .gal-track figure{aspect-ratio:3/2}
.gal-ooh .gal-view{aspect-ratio:2/1}
.gal-ooh .gal-track figure{aspect-ratio:16/9}

/* Duo: vertical film + photo / gallery */
.duo{display:grid;grid-template-columns:minmax(0,34fr) minmax(0,66fr);gap:12px}
.duo-film{margin:0;display:flex;flex-direction:column;gap:6px;min-width:0}
.duo-film video{width:100%;aspect-ratio:9/16;display:block;background:#000;object-fit:cover}
.duo-img{margin:0;display:flex;flex-direction:column;gap:6px;min-width:0}
.duo-img img{width:100%;flex:1;min-height:0;object-fit:cover;display:block;background:var(--tag)}
.duo-fit{grid-template-columns:minmax(0,9fr) minmax(0,25.6fr)}
.duo-fit .duo-img img{flex:none;aspect-ratio:1.6;height:auto;object-fit:cover;object-position:100% 50%}

footer{padding:clamp(80px,10vw,160px) var(--side) var(--side);display:flex;flex-direction:column;gap:8px;font-size:13px;align-items:flex-end;text-align:right}

@media (min-width:900px){
  article > p,article > .result{width:50%;margin-left:auto!important}
  article > dl.meta{width:50%}
  article > .label{margin-top:8px}
  article > .label.sub{width:50%;margin-left:auto!important;margin-top:24px}
  article > .aside-fig{width:50%;margin-left:auto!important}  /* sketches and screenshots sit on the text column */
  .gal-fit3 .gal-view{height:min(calc((100vw - 2 * var(--side) - 16px) / var(--fit,2.35)),640px)}  /* three portraits side by side without sliding; --fit = sum of their width/height ratios (2.35 for 4:5+3:4+4:5, 2 for three 2:3) */
  article > .slider,article > .gal,article > .duo{margin-top:24px;margin-bottom:24px}
}
@media (max-width:899px){
  .about{grid-template-columns:minmax(max-content,1.6fr) minmax(0,4fr);grid-template-areas:"title role" ". lead" ". profile";row-gap:0}
  .about .profile{margin-top:clamp(32px,5vw,56px)}
}
@media (max-width:560px){
  .about{grid-template-columns:1fr;grid-template-areas:"title" "role" "lead" "profile"}
  .about-title{text-align:left;margin-bottom:28px}
  .about .profile{grid-template-columns:1fr;gap:0}
  .about .profile dd{margin-bottom:12px}
  .about .profile .nb{display:inline}
  .index a{grid-template-columns:1fr}
  .index a::before{width:60%}
  .index .r{display:none}
  dl.meta{grid-template-columns:1fr;gap:0}
  dl.meta dd{margin-bottom:8px}
  .gal-tall .gal-view{height:min(80vw,320px)}
  .gal-wide .gal-view{aspect-ratio:auto;height:min(60vw,300px)}
  .duo{grid-template-columns:1fr}
  .duo-film{max-width:320px;width:100%;margin-inline:auto}
  .duo-img img{flex:none;aspect-ratio:16/9}
  .gal-view{flex:none;height:min(110vw,460px)}
}
@media (prefers-reduced-motion: reduce){.about[data-reveal] *{transition:none!important}body,.track figure,.index a,.tab{transition:none}}
[hidden]{display:none!important}

/* Fish cursor: follows the pointer, turns toward where it swims, takes the current text colour. Mouse/trackpad only. */
.fish{display:none}
@media (hover:hover) and (pointer:fine){
  html.has-fish,html.has-fish a,html.has-fish figure{cursor:none}
  .fish{display:block;position:fixed;left:0;top:0;width:46px;height:28px;pointer-events:none;z-index:1000;transform-origin:88% 50%;transition:opacity .25s,width .35s var(--ease),height .35s var(--ease);will-change:transform}
  .fish svg{width:100%;height:100%;overflow:visible;display:block;transition:transform .35s var(--ease)}
  .fish .body,.fish .tail path,.fish .fin{fill:var(--fg);transition:fill .9s var(--ease)}
  .fish .eye{fill:var(--bg);transition:fill .9s var(--ease)}
  .fish .tail{transform-origin:15px 14px;animation:fish-tail .5s ease-in-out infinite alternate}
  .fish.big svg{transform:scale(1.7)}
  .fish.off{opacity:0}
  .ripples{position:fixed;inset:0;width:100vw;height:100vh;pointer-events:none;z-index:999}
}
@keyframes fish-tail{from{transform:rotate(-16deg)}to{transform:rotate(16deg)}}
@media (prefers-reduced-motion: reduce){.fish .tail{animation:none}}

/* Case page: bar above the hero, next-case link at the end */
.case-bar{display:flex;justify-content:space-between;align-items:baseline;gap:16px;padding:var(--side)}
.case-bar a{text-decoration:none;font-weight:300}
.case-bar a:hover{text-decoration:underline}
.next{padding:clamp(80px,10vw,160px) var(--side) var(--side);display:flex;flex-direction:column;gap:12px;border-top:1px solid var(--line);margin-inline:var(--side);padding-inline:0}
.next-link{display:flex;justify-content:space-between;align-items:baseline;gap:16px;text-decoration:none;font-weight:200;font-size:clamp(32px,5vw,84px);line-height:1.1;transition:padding .45s var(--ease)}
.next-link .arw{font-weight:200;transition:transform .45s var(--ease)}
.next-link:hover{padding-left:16px}
.next-link:hover .arw{transform:translateX(12px)}
.next .back{align-self:flex-start;margin-top:clamp(48px,6vw,96px);font-size:13px}
main{animation:page-in .7s var(--ease) both}
@keyframes page-in{from{opacity:0;transform:translateY(16px)}}

/* Colour wipe when moving to a case page */
.wipe{position:fixed;inset:0;z-index:960;pointer-events:none;clip-path:circle(0 at var(--x) var(--y));animation:wipe .65s var(--ease) forwards}
@keyframes wipe{to{clip-path:circle(150vmax at var(--x) var(--y))}}
@media (prefers-reduced-motion: reduce){main{animation:none}}

/* Works menu (case pages): wavy-line button, indigo panel that grows from the top right */
.bar-r{display:flex;align-items:center;gap:20px}
.menu-btn,.menu-close{all:unset;cursor:pointer;width:40px;height:40px;display:grid;place-items:center;margin:-10px -8px -10px 0;border-radius:50%}
.menu-btn:focus-visible,.menu-close:focus-visible{outline:1px solid currentColor;outline-offset:2px}
.waves{width:28px;height:20px;overflow:hidden}
.waves path{fill:none;stroke:currentColor;stroke-width:1.3;stroke-linecap:round}
.waves g{transition:transform .5s var(--ease)}
.menu-btn:hover .waves g{animation:drift 1.2s linear infinite}
@keyframes drift{to{transform:translateX(14px)}}
.menu{position:fixed;inset:0;z-index:950;overflow-y:auto;overscroll-behavior:contain;
  --bg:var(--base-bg);--fg:var(--base-fg);
  --muted:color-mix(in srgb,var(--fg) 62%,transparent);--line:color-mix(in srgb,var(--fg) 24%,transparent);
  background:var(--bg);color:var(--fg);clip-path:circle(0 at calc(100% - var(--side) - 12px) calc(var(--side) + 10px));transition:clip-path .65s var(--ease)}
.menu.open{clip-path:circle(150vmax at calc(100% - var(--side) - 12px) calc(var(--side) + 10px))}
.menu-bar{display:flex;justify-content:space-between;align-items:center;padding:var(--side)}
.menu-bar a{text-decoration:none;font-weight:300}
.menu-bar a:hover{text-decoration:underline}
.menu-close{position:relative}
.menu-close span{position:absolute;left:50%;top:50%;width:24px;height:1.3px;background:currentColor;transform:translate(-50%,-50%) rotate(45deg)}
.menu-close span+span{transform:translate(-50%,-50%) rotate(-45deg)}
.menu-body{padding:clamp(24px,6vh,80px) var(--side) var(--side)}
.menu-body > .label{display:block;margin-bottom:12px}
.menu .index a[aria-current="page"] .t{font-style:italic}
.menu .index a[aria-current="page"]::before{opacity:.45}
@media (prefers-reduced-motion: reduce){.menu{transition:none}.menu-btn:hover .waves g{animation:none}}

/* Contact mail link (top page footer) */
footer .mail{font-weight:200;font-size:clamp(20px,2.4vw,36px);letter-spacing:.01em;text-decoration:none;background:linear-gradient(currentColor,currentColor) 0 100%/0 1px no-repeat;transition:background-size .5s var(--ease)}
footer .mail:hover,footer .mail:focus-visible{background-size:100% 1px}

/* Section label inside a case text (e.g. "Film", "Pop-up & Event"): sits on the text column, a step above its paragraph */
article > .label.sub{margin-bottom:-12px}

/* Smaller supporting image inside a case (concept sketch, screenshots) */
article > .aside-fig{margin:8px 0;display:flex;flex-direction:column;gap:8px}
article > .aside-fig img{width:100%;height:auto;display:block}

/* Embedded YouTube film */
.film iframe{width:100%;aspect-ratio:16/9;display:block;border:0;background:#000}

/* Small outbound link under a case text (e.g. the original Instagram post) */
article > p.ext{font-family:var(--mono);font-size:11px;letter-spacing:.08em;margin-top:-8px}
article > p.ext a{color:var(--muted);text-decoration:none;border-bottom:1px solid var(--line);padding-bottom:2px;transition:color .3s,border-color .3s}
article > p.ext a:hover{color:var(--fg);border-color:var(--fg)}

/* Text beside a supporting image (OLIVE YOUNG concept sketch): image on the left half, text on the right text column on PC; stacked text → image on smaller screens */
.split{display:flex;flex-direction:column;gap:24px}
.split-text{display:flex;flex-direction:column;gap:12px}
.split-text .label{margin-top:28px}
.split-text p{font-size:16px;margin:0}
.split-fig{margin:8px 0;display:flex;flex-direction:column;gap:8px}
.split-fig img{width:100%;height:auto;display:block}
@media (min-width:900px){
  .split{display:grid;grid-template-columns:1fr calc((100% + 2 * var(--side)) / 2);gap:0;align-items:start;margin-top:24px}
  .split-text{grid-column:2;grid-row:1}
  .split-fig{grid-column:1;grid-row:1;margin:0 0 0 12%;width:min(72%,440px)}
}

/* Social posts: phone screenshots scattered like prints on a table, each a little tilted and overlapping; they straighten and lift on hover */
.posts{margin:clamp(32px,5vw,72px) 0;display:flex;flex-direction:column;gap:16px}
.posts ul{list-style:none;margin:0;padding:clamp(16px,3vw,40px) 0;display:grid;grid-template-columns:repeat(4,1fr);gap:28px 0}
.posts li{position:relative;margin-inline:-4%;transform:translateY(var(--y,0)) rotate(var(--r,0deg));transition:transform .5s var(--ease),box-shadow .5s var(--ease);box-shadow:0 10px 30px -8px rgba(0,0,0,.35),0 2px 6px rgba(0,0,0,.12);z-index:var(--z,1)}
.posts li img{width:100%;height:auto;display:block}
.posts li:nth-child(1){--r:-5deg;--y:10px;--z:2}
.posts li:nth-child(2){--r:3deg;--y:-14px;--z:3}
.posts li:nth-child(3){--r:-2deg;--y:18px;--z:1}
.posts li:nth-child(4){--r:6deg;--y:-4px;--z:2}
.posts li:nth-child(5){--r:4deg;--y:-6px;--z:3}
.posts li:nth-child(6){--r:-4deg;--y:14px;--z:1}
.posts li:nth-child(7){--r:2deg;--y:-12px;--z:2}
.posts li:nth-child(8){--r:-6deg;--y:8px;--z:3}
@media (hover:hover){.posts li:hover{transform:translateY(calc(var(--y,0) - 10px)) rotate(0deg) scale(1.04);z-index:10;box-shadow:0 22px 50px -10px rgba(0,0,0,.45)}}
@media (min-width:900px){
  .posts ul{grid-template-columns:repeat(8,1fr);padding-inline:2%}
  .posts li{margin-inline:-6%}
}
