/* Self-hosted fonts (were a Google Fonts @import: a slow CSS->CSS->font chain
   that painted a fallback font first and then swapped). Preloaded in <head>;
   font-display:block so text never flashes in the wrong typeface. */
/* vietnamese */
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 400 800;
  font-display: block;
  src: url(/assets/theme/fonts/jetbrains-mono-vietnamese.woff2) format('woff2');
  unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB;
}
/* latin-ext */
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 400 800;
  font-display: block;
  src: url(/assets/theme/fonts/jetbrains-mono-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* latin */
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 400 800;
  font-display: block;
  src: url(/assets/theme/fonts/jetbrains-mono-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* vietnamese */
@font-face {
  font-family: 'Road Rage';
  font-style: normal;
  font-weight: 400;
  font-display: block;
  src: url(/assets/theme/fonts/road-rage-vietnamese.woff2) format('woff2');
  unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB;
}
/* latin-ext */
@font-face {
  font-family: 'Road Rage';
  font-style: normal;
  font-weight: 400;
  font-display: block;
  src: url(/assets/theme/fonts/road-rage-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* latin */
@font-face {
  font-family: 'Road Rage';
  font-style: normal;
  font-weight: 400;
  font-display: block;
  src: url(/assets/theme/fonts/road-rage-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root{
    --ink:oklch(14% 0.004 49.25);
    --base-200:oklch(21% 0.006 56.043);
    --base-300:oklch(26% 0.007 34.298);
    --base-400:oklch(37% 0.01 67.558);
    --base-500:oklch(44% 0.011 73.639);
    --muted:oklch(70% 0.01 56.259);
    --base-800:oklch(86% 0.005 56.366);
    --paper:oklch(98% 0.001 106.423);
    --grunge:"Road Rage",cursive;
    --mono:"JetBrains Mono",monospace;
    --img-rest:sepia(.4) grayscale(30%) brightness(.62) contrast(1.08) saturate(.5);
    --img-hover:sepia(0) grayscale(0%) brightness(1) contrast(1) saturate(1);
    --canvas-max:1680px;
    --canvas-pad:clamp(24px,7vw,110px);
    /* Fixed (never flips with theme) — for the handful of decorative marks
       (the work-card paper tag, the barcode/symbol marks drawn straight onto
       the page) that are meant to read as cream-paper-with-black-ink always,
       not as "background vs foreground" that inverts with the rest of the
       site. */
    --paper-fixed:oklch(98% 0.001 106.423);
    --ink-fixed:oklch(14% 0.004 49.25);
}
/* LIGHT MODE — the whole site is built on --ink (background) and --paper
   (text/borders), so redefining just those two tokens (plus the base-*
   scale and --muted, used for secondary surfaces/text) inverts the entire
   site in one place rather than touching every rule that uses them. */
:root[data-theme="light"]{
    --ink:oklch(98% 0.001 106.423);
    --base-200:oklch(93% 0.004 56.043);
    --base-300:oklch(89% 0.005 34.298);
    --base-400:oklch(80% 0.008 67.558);
    --base-500:oklch(72% 0.009 73.639);
    --muted:oklch(42% 0.015 56.259);
    --base-800:oklch(22% 0.006 56.366);
    --paper:oklch(16% 0.004 49.25);
}
[data-theme="light"] body:before{opacity:.05}
/* These marks are baked white-on-transparent SVGs drawn straight onto the
   page background (not inside a fixed-color card), so they need to flip to
   black ink when the background itself flips to light. */
[data-theme="light"] .bottom-mark img.symbol,
[data-theme="light"] .contact-item .row img{filter:invert(1)}
*{box-sizing:border-box;min-width:0}
html{scroll-behavior:smooth}
html.no-preloader #preloader{display:none}
body{
    margin:0;
    color:var(--paper);
    font-family:var(--mono);
    background-color:var(--ink);
    overflow-x:clip;
    position:relative;
    max-width:100vw;
}
/* The paper texture lives on its own viewport-sized fixed layer instead of
   background-attachment:fixed, which mobile browsers ignore (they stretch the
   image over the whole page height, so the texture looked blown-up/different
   on phones). A fixed layer renders identically on every device and never
   repaints on scroll. */
body:after{
    content:"";
    position:fixed;inset:0;z-index:-1;pointer-events:none;
    background:url("/assets/theme/bg.jpg") center top/cover no-repeat;
}
[data-theme="light"] body:after{display:none}
/* Overlays that carry the dark paper photo must drop it in light mode too,
   otherwise light-mode (dark) text lands on a dark image and vanishes. */
[data-theme="light"] .mobile-nav,
[data-theme="light"] #gate{background-image:none}
/* Moving film grain for touch/small screens, where the WebGL grain shader is
   skipped for performance — a transform-only animation, so it stays on the
   compositor and costs nothing while scrolling. */
.grain-css{position:fixed;inset:-50%;z-index:2;pointer-events:none;opacity:.35;mix-blend-mode:overlay;
    background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200'%3E%3Cfilter id='n'%3E%3CfeTurbulence baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
    animation:grain-shift .5s steps(5) infinite;will-change:transform}
@keyframes grain-shift{
    0%{transform:translate(0,0)}20%{transform:translate(-7%,4%)}40%{transform:translate(5%,-6%)}
    60%{transform:translate(-4%,-3%)}80%{transform:translate(6%,5%)}100%{transform:translate(0,0)}}
@media (prefers-reduced-motion:reduce){.grain-css{animation:none}}
body:before{
    content:"";
    position:fixed;inset:0;z-index:1;pointer-events:none;
    opacity:.15;mix-blend-mode:overlay;
    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 baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
body.menu-open,body.lock-scroll{overflow:hidden}
/* Locked from the very first paint (inline script, before body even exists)
   until the preloader finishes, so a scroll/swipe gesture during gate or
   preload can never reveal real page content peeking out from behind the
   fixed overlay — a known mobile browser quirk with position:fixed during
   momentum scrolling. */
/* Nothing of the real site is even painted until the visitor has said yes
   at the gate AND the preloader has finished — not just covered by the
   overlays, but invisible — so no scroll quirk, slow overlay, back-button
   restore or failed animation can ever let it show through. */
html.veil .wrap,html.veil .nav,html.veil .mobile-nav,html.veil #cookie-banner,html.veil #exit-popup,html.veil .grain-css{visibility:hidden}
html.no-scroll,html.no-scroll body{overflow:hidden;height:100%;touch-action:none}
a{color:inherit;text-decoration:none}
img,video{display:block;max-width:100%}
img{height:auto}
button{font:inherit;color:inherit;background:none;border:none;cursor:pointer}
ul{margin:0;padding:0;list-style:none}
svg{display:block}

/* ============ TYPOGRAPHY SYSTEM ============
   Display (Road Rage): .h1 hero name, .h2 section headings, .h3 sub-headings,
   .h4 project/card titles, .h5 fact labels, .h6 footer/nav-column labels.
   Mono (JetBrains Mono): .t-xsm metadata, .t-sm body copy, .t-md eyebrow/
   labels, .t-lg/.t-xl quoted or emphatic statements. Nothing outside this
   scale should appear anywhere in the site. */
.h1,.h2,.h3,.h4,.h5,.h6{font-family:var(--grunge);text-transform:uppercase;letter-spacing:-.01em;line-height:.9;color:var(--paper);margin:0}
.h1{font-size:clamp(3.4rem,15vw,6.2rem)}
.h2{font-size:clamp(2.6rem,9vw,4.2rem)}
.h3{font-size:clamp(2rem,6vw,2.6rem)}
.h4{font-size:clamp(1.5rem,4vw,2rem)}
.h5{font-size:1.2rem}
.h6{font-size:1rem;letter-spacing:.04em}
@media(min-width:768px){.h1{font-size:clamp(6rem,13vw,8.5rem)}.h2{font-size:clamp(4rem,8vw,5.2rem)}.h3{font-size:3rem}.h4{font-size:2.5rem}.h5{font-size:1.5rem}}
@media(min-width:1200px){.h1{font-size:clamp(8.5rem,12vw,13.5rem)}.h2{font-size:clamp(5.2rem,7vw,8rem)}.h3{font-size:5rem}.h4{font-size:3rem}.h5{font-size:2rem}.h6{font-size:1.25rem}}
.text-center{text-align:center}
.t-xsm{font-size:.75rem;font-family:var(--mono);letter-spacing:.03em}
.t-sm{font-size:.95rem;line-height:1.8;font-family:var(--mono)}
@media(min-width:768px){.t-sm{font-size:1rem}}
.t-md{font-size:1.1rem;font-family:var(--mono);font-weight:600;text-transform:uppercase;color:var(--muted);letter-spacing:.02em}
@media(min-width:768px){.t-md{font-size:1.25rem}}
.t-lg{font-size:1.6rem;font-family:var(--grunge);line-height:1.05}
.t-xl{font-size:1.9rem;font-family:var(--grunge);line-height:1.05}
@media(min-width:768px){.t-lg{font-size:2.2rem}.t-xl{font-size:2.6rem}}

/* ============ BOXED CANVAS ============
   The whole site sits inside one consistent, generously-margined canvas
   rather than stretching edge-to-edge, echoing the reference's contained
   composition. Section max-widths (container-xl/lg/md) sit inside this. */
.wrap{position:relative;z-index:20;max-width:var(--canvas-max);margin:0 auto;padding:96px var(--canvas-pad) 0}
@media(min-width:768px){.wrap{padding-top:126px}}
main{display:flex;flex-direction:column;gap:6rem;padding-bottom:2rem}
@media(min-width:768px){main{gap:8rem}}
@media(min-width:1200px){main{gap:10rem}}
.container{width:100%;margin:0 auto;display:flex;flex-direction:column;gap:2.5rem}
@media(min-width:768px){.container{gap:3rem}}
.container-xl{max-width:1500px}
.container-lg{max-width:1150px}
.container-md{max-width:800px}

/* NAV */
.nav{display:flex;align-items:center;justify-content:flex-end;gap:1rem;position:fixed;top:0;right:0;left:0;z-index:50;padding:1.2rem var(--canvas-pad) 0}
.nav-logo{margin-right:auto;display:block;flex-shrink:0}
.nav-logo img{height:36px;width:auto;transition:opacity .2s}
.nav-logo:hover img{opacity:.7}
@media(min-width:768px){.nav-logo img{height:46px}}
.mobile-nav-logo{display:block;margin-bottom:2.2rem}
.mobile-nav-logo img{height:56px;width:auto}
[data-theme="light"] .nav-logo img,[data-theme="light"] .mobile-nav-logo img{filter:invert(1)}
.nav ul{display:none;gap:2rem}
.nav a{font-family:var(--grunge);font-size:1.4rem;text-transform:uppercase;text-underline-offset:4px;text-decoration:underline;letter-spacing:.02em;transition:color .2s}
.nav a:hover{color:var(--muted)}
/* Current section: faded, so it reads as "you are here". */
.nav a[aria-current="page"],.mobile-nav a[aria-current="page"]{opacity:.42;text-decoration-thickness:1px}
.nav a[aria-current="page"]:hover{color:inherit}
.menu-btn{display:flex;align-items:center;justify-content:center;width:36px;height:36px;padding:0;color:var(--paper);border:2px solid var(--paper);border-radius:50%;flex-shrink:0;position:relative;transition:background .2s,color .2s;-webkit-tap-highlight-color:transparent}
/* Invisible 44px hit area around the 36px circle, for comfortable tapping. */
.menu-btn:before{content:"";position:absolute;inset:-5px}
.menu-btn svg{width:16px;height:16px}
.menu-btn .menu-bar{fill:currentColor;transform-box:fill-box;transform-origin:left center;transition:transform .3s cubic-bezier(.3,1.4,.5,1)}
.menu-btn:hover,.menu-btn:focus-visible{background:var(--paper);color:var(--ink)}
.menu-btn:hover .menu-bar-1,.menu-btn:focus-visible .menu-bar-1{transform:scaleX(.64)}
.menu-btn:hover .menu-bar-2,.menu-btn:focus-visible .menu-bar-2{transform:scaleX(1.56)}
.menu-btn:active{transform:scale(.92)}
@media(min-width:768px){.nav ul{display:flex}.menu-btn{display:none}}
.mobile-nav{display:none;position:fixed;inset:0;background:var(--ink) url("/assets/theme/bg.jpg") center top/cover no-repeat;z-index:60;flex-direction:column;align-items:center;justify-content:center;overflow-y:auto}
.mobile-nav:before{content:"";position:absolute;inset:0;pointer-events:none;opacity:.15;mix-blend-mode:overlay;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 baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E")}
.mobile-nav ul,.mobile-nav-controls,.mobile-nav .close-btn,.mobile-nav-logo{position:relative;z-index:1}
.mobile-nav.open{display:flex}
.mobile-nav .close-btn{position:absolute;top:24px;right:24px;min-height:44px;min-width:44px}
.mobile-nav .close-btn svg path{stroke:var(--paper)}
.mobile-nav-controls{position:absolute;top:24px;left:24px;display:flex;align-items:center;gap:.6rem}
.mobile-nav ul{display:flex;flex-direction:column;gap:1.5rem;text-align:center;padding:1.5rem}
.mobile-nav a{font-family:var(--grunge);font-size:2.6rem;text-transform:uppercase;display:inline-block;padding:.4rem}

/* THEME TOGGLE */
.theme-toggle{display:flex;align-items:center;justify-content:center;width:32px;height:32px;color:var(--paper);border:2px solid var(--paper);border-radius:50%;transition:background .2s,color .2s;flex-shrink:0}
.theme-toggle svg{width:16px;height:16px}
.theme-toggle:hover{background:var(--paper);color:var(--ink)}
.nav .theme-toggle.desktop-only{display:none;margin-left:1.25rem}
/* X-RAY MODE toggle: same outlined circle as the theme toggle, with a mono X. */
.xray-toggle{display:flex;align-items:center;justify-content:center;width:32px;height:32px;color:var(--paper);border:2px solid var(--paper);border-radius:50%;font-family:var(--mono);font-size:.8rem;font-weight:700;line-height:1;transition:background .2s,color .2s,border-color .2s;flex-shrink:0}
.xray-toggle:hover{background:var(--paper);color:var(--ink)}
.xray-toggle[aria-pressed="true"]{background:var(--xray);border-color:var(--xray);color:#06121c}
.nav .xray-toggle.desktop-only{display:none;margin-left:1.25rem}
@media(min-width:768px){.nav .xray-toggle.desktop-only{display:flex}}
@media(min-width:768px){.nav .theme-toggle.desktop-only{display:flex}}

/* ============ LANGUAGE SWITCHER ============
   Tiny globe button that reveals a short dropdown of languages. Same
   instance is reused in the nav (desktop + mobile) and pinned small in the
   landing gate, so the choice is available right from the first banner. */
.lang-switcher{position:relative;flex-shrink:0}
.nav .lang-switcher.desktop-only{display:none;margin-left:.5rem}
@media(min-width:768px){.nav .lang-switcher.desktop-only{display:block}}
.lang-toggle{display:flex;align-items:center;gap:.3rem;height:32px;padding:0 .55rem;color:var(--paper);background:transparent;border:2px solid var(--paper);border-radius:999px;font-family:var(--mono);font-size:.68rem;letter-spacing:.03em;text-transform:uppercase;cursor:pointer;transition:background .2s,color .2s}
.lang-toggle:hover{background:var(--paper);color:var(--ink)}
/* Dropdown: a rounded panel in the same outline language as the pill,
   opening flush with the pill's outer edge — right-aligned where the
   switcher sits on the right (header, landing banner), left-aligned in the
   mobile menu where it sits top-left — so it never hangs off-centre. */
.lang-menu{display:none;position:absolute;top:calc(100% + .45rem);right:0;min-width:max(100%,8.25rem);flex-direction:column;padding:.3rem;background:var(--ink);border:2px solid var(--paper);border-radius:16px;box-shadow:0 14px 34px rgba(0,0,0,.45);z-index:50}
.mobile-nav-controls .lang-menu{right:auto;left:0}
.lang-switcher.open .lang-menu{display:flex}
.lang-option{width:100%;text-align:left;padding:.5rem .75rem;border-radius:10px;background:transparent;color:var(--paper);font-family:var(--mono);font-size:.8rem;cursor:pointer;transition:background .2s,color .2s}
.lang-option:hover{background:var(--paper);color:var(--ink)}
.lang-option[aria-current="true"]{font-weight:700;text-decoration:underline;text-underline-offset:3px}
.gate-lang{position:absolute;top:1.5rem;right:var(--canvas-pad);z-index:1}

/* BUTTON / LINKS */
.btn{display:inline-block;font-family:var(--grunge);text-transform:uppercase;letter-spacing:.02em;font-size:1.3rem;padding:.7rem 1.6rem;border:2px solid var(--paper);transition:background .2s,color .2s;min-height:44px}
.btn:hover{background:var(--paper);color:var(--ink)}
.link-inline{font-family:var(--mono);font-weight:600;text-decoration:underline;text-underline-offset:3px}
.link-inline:hover{color:var(--muted)}
.social-row{display:flex;flex-wrap:wrap;gap:1rem 1.5rem;margin-top:.5rem}

/* ============ IMAGE COLOUR TREATMENT ============
   Resting state reads dark/muted/integrated with the grunge background;
   hovering (or focus, for keyboard users) gradually reveals full colour and
   brightness — applied directly on each photographic image selector below
   (work-card thumbs, masonry, gallery grids, image-frame photos). The
   filter never touches the underlying file, only how it's painted. */

/* IMAGE FRAME (barcode + bordered photo) — the box sizes to the image's own
   natural dimensions rather than the image being squeezed/cropped to fit a
   fixed box. A max-height only guards against one wildly tall source photo
   dominating the page; object-fit:contain there is a safety net, never the
   normal path. */
.image-frame{display:flex;flex-direction:column;align-items:flex-end;gap:.5rem;width:100%}
/* Project/credential frames: full width; tall full-page screenshots are
   cropped neatly from the top (cover), so the image always fills its box. */
.image-frame .frame-box{border:2px solid var(--paper);width:100%;display:flex;align-items:center;justify-content:center;overflow:hidden}
.image-frame .frame-box img{width:100%;height:auto;max-height:78vh;object-fit:cover;object-position:top;cursor:zoom-in;filter:var(--img-rest);transition:transform .5s cubic-bezier(.2,.8,.2,1),filter .6s ease}
.image-frame .frame-box:hover img,.image-frame .frame-box:focus-within img{transform:scale(1.02);filter:var(--img-hover)}
.image-frame .frame-box:has(video){width:100%}
.image-frame .frame-box video{width:100%;height:auto;object-fit:contain}

/* BOTTOM MARK (symbol + barcode row under accordion boxes) */
.bottom-mark{display:flex;justify-content:space-between;align-items:center;margin-top:.5rem}
.bottom-mark img.symbol{width:36px;height:20px}

/* HERO */
.hero{min-height:88vh;display:flex;flex-direction:column;gap:2rem;justify-content:center}
.hero .tagline{max-width:34rem}
.hero-main{display:flex;flex-direction:column;gap:2rem}
.hero-main .hero-copy{display:flex;flex-direction:column;align-items:flex-start;gap:1rem}
.hero-photo{width:100%;max-width:640px}
@media(min-width:768px){.hero-main{flex-direction:row;gap:2rem;align-items:center}.hero-main .hero-copy{flex:0 1 auto;max-width:48%}.hero-photo{flex:0 1 auto;max-width:min(640px,50%);display:flex;justify-content:flex-end}}

/* SPLIT (about / intro sections) */
.split{display:flex;flex-direction:column;gap:2.5rem}
.split-copy{display:flex;flex-direction:column;align-items:flex-start;gap:1.5rem}
.split-photo{width:100%;max-width:640px;margin:0 auto}
@media(min-width:768px){.split{flex-direction:row;gap:4rem;align-items:center}.split-copy{flex:1}.split-photo{flex:0 1 auto;max-width:min(640px,50%);margin:0}}

/* Single-portrait frames (home hero, about-section photos): crop tight to
   the subject via a fixed aspect-ratio + object-fit:cover instead of
   showing the full source photo's empty studio background, which made the
   frame read as far bigger than the person inside it. */
/* Portraits: the frame hugs the photo exactly, at the same size the
   lightbox shows it (up to 88% of the screen height). */
.image-frame.portrait .frame-box{width:fit-content;max-width:100%}
.image-frame.portrait .frame-box img{width:auto;max-width:100%;max-height:88vh;object-fit:contain}

/* WORK CARD */
/* Works filter (Vue-rendered chips; hidden entirely without JS) */
.works-filter:empty{display:none}
.works-filter{display:flex;flex-wrap:wrap;justify-content:center;gap:.5rem;margin:0 auto 3rem;max-width:44rem}
.filter-chip{display:inline-flex;align-items:center;gap:.45rem;min-height:38px;padding:.35rem .95rem;border:2px solid var(--paper);border-radius:999px;font-family:var(--mono);font-size:.78rem;text-transform:uppercase;letter-spacing:.04em;color:var(--paper);transition:background .2s,color .2s}
.filter-chip sup{font-size:.62rem;opacity:.7;top:0}
.filter-chip:hover,.filter-chip.is-active{background:var(--paper);color:var(--ink)}
.work-card[hidden]{display:none!important}
.work-grid{display:grid;grid-template-columns:1fr;gap:3.5rem;justify-content:center}
@media(min-width:600px){.work-grid{grid-template-columns:repeat(2,minmax(0,420px));gap:3.5rem 2rem}}
/* An odd card out on the last row sits centred rather than stranded left. */
@media(min-width:600px){.work-grid>.work-card:last-child:nth-child(odd){grid-column:1/-1;justify-self:center;width:100%;max-width:420px}}
.work-card{display:block;width:100%;max-width:420px;margin:0 auto}
.work-card .frame{position:relative;width:100%;aspect-ratio:1/1;overflow:visible}
.work-card .label{position:absolute;top:8px;left:8px;z-index:40;background:var(--paper-fixed);border:2px solid var(--ink-fixed);color:var(--ink-fixed);padding:2px 14px;display:flex;align-items:center;gap:8px;max-width:calc(100% - 60px)}
.work-card .label span{font-family:var(--grunge);font-size:1.15rem;text-transform:uppercase;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.work-card .label img{width:26px;flex-shrink:0}
.work-card .texture{position:absolute;inset:0;z-index:30;background-image:url("/assets/theme/vinyl-texture.jpg");background-size:cover;opacity:.4}
.work-card .thumb{position:relative;z-index:20;width:100%;height:100%;object-fit:cover;object-position:top;filter:var(--img-rest);transition:filter .6s ease}
.work-card:hover .thumb,.work-card:focus-visible .thumb{filter:var(--img-hover)}
/* PLACEHOLDER ("visuals coming soon" case file) — fixed paper/ink tokens so
   it reads the same in light or dark theme. */
.ph{position:relative;z-index:20;width:100%;height:100%;min-height:240px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:.9rem;padding:2rem 1.5rem;text-align:center;overflow:hidden;color:var(--paper-fixed);
    background:repeating-linear-gradient(135deg,rgba(238,234,224,.045) 0 1px,transparent 1px 11px),radial-gradient(120% 90% at 50% 40%,#1d1b19 0%,#0e0d0c 70%)}
.ph-corner{position:absolute;width:14px;height:14px;border:0 solid rgba(238,234,224,.55)}
.ph-corner.tl{top:12px;left:12px;border-top-width:2px;border-left-width:2px}
.ph-corner.tr{top:12px;right:12px;border-top-width:2px;border-right-width:2px}
.ph-corner.bl{bottom:12px;left:12px;border-bottom-width:2px;border-left-width:2px}
.ph-corner.br{bottom:12px;right:12px;border-bottom-width:2px;border-right-width:2px}
.ph-cat{font-family:var(--mono);font-size:.66rem;font-weight:700;letter-spacing:.16em;text-transform:uppercase;color:rgba(238,234,224,.55)}
.ph-title{font-family:var(--grunge);text-transform:uppercase;line-height:.9;font-size:clamp(2.2rem,7vw,4rem);max-width:12ch}
.ph-stamp{margin-top:.4rem;padding:.35rem .8rem;border:2px solid currentColor;border-radius:6px;font-family:var(--mono);font-size:.68rem;font-weight:800;letter-spacing:.16em;text-transform:uppercase;transform:rotate(-4deg);opacity:.8}
.frame-ph{aspect-ratio:16/10}
.frame-ph .ph{min-height:0}
.work-card .ph{position:absolute;inset:0}
.work-card .disk{position:absolute;top:0;right:-48px;z-index:0;width:100%;height:100%;background-image:url("/assets/theme/vinyl-disk.png");background-size:cover;transition:right .5s ease-in-out;animation:spin 6s linear infinite}
.work-card:hover .disk{right:-96px}
@keyframes spin{from{transform:rotate(0)}to{transform:rotate(360deg)}}
.work-card .meta{margin-top:1rem}
.work-card .meta h3{transition:color .2s}
.work-card:hover .meta h3{text-decoration:underline}
.work-card .meta p{margin:.4rem 0 0}

/* ACCORDION */
.accordion-box{border:3px solid var(--paper);padding:1.5rem;display:flex;flex-direction:column;gap:1rem}
.accordion-item{display:flex;flex-direction:column;gap:.5rem;border-bottom:1px solid rgba(238,238,230,.2);padding-bottom:1rem}
.accordion-item:last-child{border-bottom:none;padding-bottom:0}
.accordion-trigger{display:flex;justify-content:space-between;align-items:center;width:100%;text-align:left;gap:1rem;min-height:44px}
.accordion-trigger .num{font-family:var(--grunge)}
.accordion-trigger .chevron{transition:transform .2s;flex-shrink:0}
.accordion-trigger .chevron path{fill:var(--paper)}
.accordion-item.open .chevron{transform:rotate(180deg)}
.accordion-content{display:none;padding-top:.25rem}
.accordion-item.open .accordion-content{display:block}
.accordion-item .place{margin:.3rem 0 0}
.accordion-item .period{margin:.2rem 0 0;color:var(--muted)}

/* FACTS ROW (project detail) */
/* PROJECT SPEC PANEL — the site's 2px paper frame split into cells by
   hairlines. Label: tiny numbered mono caps. Value: display face. Services:
   outlined pill tags. Phones: 2x2 with services full width; desktop: 4 across. */
.spec{--hair:color-mix(in oklch,var(--paper) 18%,transparent);width:100%;max-width:64rem;margin:0;display:grid;grid-template-columns:1fr 1fr;border:2px solid var(--paper);background:color-mix(in oklch,var(--ink) 70%,transparent)}
.spec-item{display:flex;flex-direction:column;gap:.7rem;padding:1.1rem 1.15rem 1.25rem;min-width:0}
.spec-client{border-right:1px solid var(--hair)}
.spec-category,.spec-services{grid-column:1/-1;border-top:1px solid var(--hair)}
.spec dt{display:flex;align-items:center;gap:.5rem;font-family:var(--mono);font-size:.62rem;font-weight:700;letter-spacing:.16em;text-transform:uppercase;color:var(--muted)}
.spec-n{display:inline-grid;place-items:center;min-width:1.7rem;height:1.15rem;padding:0 .3rem;border:1px solid var(--hair);border-radius:999px;font-size:.58rem;letter-spacing:.06em;color:var(--paper)}
.spec dd{margin:0;font-family:var(--grunge);text-transform:uppercase;font-size:clamp(1.15rem,3.6vw,1.5rem);line-height:1.05;letter-spacing:.01em;color:var(--paper);overflow-wrap:anywhere}
.spec-services dd{font-family:var(--mono);text-transform:none}
.spec-tags{display:flex;flex-wrap:wrap;gap:.4rem}
.spec-tags span{font-family:var(--mono);font-size:.74rem;font-weight:600;letter-spacing:.04em;padding:.3rem .7rem;border:1px solid color-mix(in oklch,var(--paper) 55%,transparent);border-radius:999px;white-space:nowrap;transition:background .2s,color .2s}
.spec-tags span:hover{background:var(--paper);color:var(--ink)}
@media(min-width:768px){
    .spec{grid-template-columns:1.1fr .7fr 1.2fr 1.6fr}
    .spec-item{padding:1.4rem 1.5rem 1.6rem}
    .spec-client,.spec-year,.spec-category{border-right:1px solid var(--hair)}
    .spec-category,.spec-services{grid-column:auto;border-top:none}
}
/* Country flag(s) beside the client name in the spec panel. */
.spec .flags{display:inline-flex;gap:.3rem;vertical-align:middle;margin-right:.5rem;position:relative;top:-.08em}
.spec .flag{display:inline-block;width:1.25rem;height:.85rem;line-height:0;border-radius:2px;overflow:hidden;box-shadow:0 0 0 1px rgba(238,234,224,.35)}
.spec .flag svg{width:100%;height:100%;display:block}

/* X-RAY MODE: textures fade to a blueprint grid, each section gets a dashed
   outline and a mono label naming the tech behind it, plus a live HUD. */
:root{--xray:#5cc8ff}
:root[data-theme="light"]{--xray:#0a6fb0}
.xray-tag,.xray-hud{display:none}
html.xray body{background-image:linear-gradient(color-mix(in oklch,var(--xray) 9%,transparent) 1px,transparent 1px),linear-gradient(90deg,color-mix(in oklch,var(--xray) 9%,transparent) 1px,transparent 1px);background-size:32px 32px}
html.xray body:after,html.xray body:before,html.xray #grain-canvas,html.xray .grain-css{opacity:0!important;transition:opacity .4s}
html.xray .xray-rel{position:relative}
html.xray .xray-box{outline:1px dashed var(--xray);outline-offset:-1px}
html.xray .xray-tag{display:block;position:absolute;top:0;left:0;z-index:30;max-width:calc(100% - .5rem);padding:.22rem .45rem;background:var(--xray);color:#06121c;font-family:var(--mono);font-size:.6rem;font-weight:700;letter-spacing:.06em;line-height:1.25;text-transform:uppercase;white-space:normal;pointer-events:none;animation:xray-in .35s ease-out both}
html.xray main img,html.xray footer img{filter:grayscale(1) contrast(1.05);opacity:.75;transition:filter .3s,opacity .3s}
html.xray .xray-hud{display:grid;position:fixed;right:1rem;bottom:1rem;z-index:60;gap:.2rem;min-width:13.5rem;padding:.7rem .85rem;border:1px solid var(--xray);background:color-mix(in oklch,var(--ink) 88%,transparent);backdrop-filter:blur(6px);font-family:var(--mono);font-size:.64rem;letter-spacing:.04em;color:var(--paper);pointer-events:none;animation:xray-in .35s ease-out both}
.xray-hud span{display:flex;justify-content:space-between;gap:1rem}
.xray-hud b{font-weight:700;text-transform:uppercase;color:var(--xray)}
.xray-hud i{font-style:normal}
@keyframes xray-in{from{opacity:0;transform:translateY(-4px)}to{opacity:1;transform:none}}
@media(max-width:599px){html.xray .xray-tag{font-size:.52rem}html.xray .xray-hud{left:.6rem;right:.6rem;bottom:.6rem;min-width:0;padding:.5rem .65rem;font-size:.58rem;grid-template-columns:1fr 1fr;column-gap:1rem}.xray-hud span:nth-child(5),.xray-hud span:nth-child(7){display:none}}
@media(prefers-reduced-motion:reduce){html.xray .xray-tag,html.xray .xray-hud{animation:none}}

/* FEATURED BUILD — a framed two-column panel inside a project page: the
   story on the left, the skills it shows on the right (stacked on phones). */
.feature-build{width:100%;max-width:64rem;display:grid;grid-template-columns:1fr;border:2px solid var(--paper);background:color-mix(in oklch,var(--ink) 70%,transparent)}
.fb-main{display:flex;flex-direction:column;gap:.9rem;padding:clamp(1.4rem,3.5vw,2.4rem)}
.fb-eyebrow{margin:0;font-family:var(--mono);font-size:.66rem;font-weight:700;letter-spacing:.16em;text-transform:uppercase;color:var(--muted)}
.fb-title{margin:0;font-family:var(--grunge);text-transform:uppercase;font-weight:400;line-height:.9;font-size:clamp(2.4rem,6vw,3.8rem);color:var(--paper)}
.fb-sub{margin:0 0 .4rem;font-family:var(--mono);font-size:.85rem;font-weight:700;letter-spacing:.04em;color:var(--paper)}
.fb-main .t-sm{margin:0;line-height:1.75}
.fb-top{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:.6rem}
.fb-badge{display:inline-flex;align-items:center;gap:.45rem;padding:.3rem .7rem;border:1px solid color-mix(in oklch,var(--paper) 45%,transparent);border-radius:999px;font-family:var(--mono);font-size:.66rem;font-weight:700;letter-spacing:.08em;text-transform:uppercase;color:var(--paper)}
.fb-badge i{width:.5rem;height:.5rem;border-radius:50%;background:#3ddc84;box-shadow:0 0 0 0 rgba(61,220,132,.6);animation:fb-pulse 2s ease-out infinite}
/* "Available for work": same live green pulse as the plugin version badges. */
.btn-live{display:inline-flex;align-items:center;gap:.6rem}
.live-dot{display:inline-block;flex-shrink:0;width:.55rem;height:.55rem;border-radius:50%;background:#3ddc84;box-shadow:0 0 0 0 rgba(61,220,132,.6);animation:fb-pulse 2s ease-out infinite}
@media (prefers-reduced-motion:reduce){.live-dot,.fb-badge i{animation:none}}
@keyframes fb-pulse{0%{box-shadow:0 0 0 0 rgba(61,220,132,.55)}80%,100%{box-shadow:0 0 0 7px rgba(61,220,132,0)}}
.fb-cta{align-self:flex-start;margin-top:.4rem}
.feature-build+.feature-build{margin-top:-.5rem}
.fb-proof{margin:.6rem 0 0;display:flex;flex-direction:column;gap:.5rem}
.fb-proof img{width:100%;height:auto;border:1px solid color-mix(in oklch,var(--paper) 35%,transparent);border-radius:4px;background:#fff;cursor:zoom-in}
.fb-proof figcaption{font-family:var(--mono);font-size:.7rem;letter-spacing:.04em;color:var(--muted)}
.fb-skills{padding:clamp(1.4rem,3.5vw,2.4rem);border-top:1px solid color-mix(in oklch,var(--paper) 18%,transparent)}
.fb-skills-title{margin:0 0 1rem;font-family:var(--mono);font-size:.66rem;font-weight:700;letter-spacing:.16em;text-transform:uppercase;color:var(--muted)}
.fb-skills ul{display:flex;flex-direction:column;gap:.75rem}
.fb-skills li{position:relative;padding-left:1.4rem;font-family:var(--mono);font-size:.82rem;line-height:1.5;color:var(--paper)}
.fb-skills li:before{content:"✦";position:absolute;left:0;top:.05em;font-size:.75rem;color:var(--muted)}
@media(min-width:900px){
    .feature-build{grid-template-columns:1.55fr 1fr}
    .fb-skills{border-top:none;border-left:1px solid color-mix(in oklch,var(--paper) 18%,transparent)}
}

/* PREVIOUS / ALL / NEXT */
.pager{width:100%;max-width:64rem;display:grid;grid-template-columns:1fr auto 1fr;align-items:center;gap:1rem;padding-top:2rem;border-top:1px solid color-mix(in oklch,var(--paper) 14%,transparent)}
.pager-link{display:flex;flex-direction:column;gap:.3rem;min-width:0;color:var(--paper);text-decoration:none}
.pager-next{text-align:right;align-items:flex-end}
.pager-dir{font-family:var(--mono);font-size:.66rem;font-weight:700;letter-spacing:.14em;text-transform:uppercase;color:var(--muted)}
.pager-prev .pager-dir:before{content:"← "}
.pager-next .pager-dir:after{content:" →"}
.pager-title{font-family:var(--grunge);text-transform:uppercase;font-size:clamp(1.1rem,2.6vw,1.6rem);line-height:1;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;max-width:100%;transition:color .2s}
.pager-link:hover .pager-title{color:var(--muted)}
@media(max-width:599px){.pager{grid-template-columns:1fr 1fr}.pager-all{grid-column:1/-1;grid-row:2;justify-self:center}}

/* MASONRY (editorial, natural-aspect gallery — never crops) */
.masonry{width:100%;columns:2 220px;column-gap:1rem}
/* PERSONAL ARCHIVE — compact bento of square tiles */
.bento{width:100%;max-width:62rem;margin-inline:auto;align-self:center;display:grid;grid-template-columns:repeat(3,1fr);grid-auto-rows:1fr;grid-auto-flow:dense;gap:.5rem}
@media(min-width:768px){.bento{grid-template-columns:repeat(4,1fr);gap:.75rem}}
.bento-item{margin:0;aspect-ratio:1/1;overflow:hidden;border:2px solid var(--paper);cursor:zoom-in;position:relative}
.bento-feature{grid-column:span 2;grid-row:span 2}
.bento-item img{width:100%;height:100%;object-fit:cover;object-position:50% 30%;display:block;filter:var(--img-rest);transition:transform .6s cubic-bezier(.2,.8,.2,1),filter .6s ease}
.bento-item:hover img{transform:scale(1.06);filter:var(--img-hover)}
@media(min-width:768px){.masonry{columns:3 260px}}
.masonry-item{break-inside:avoid;margin-bottom:1rem;border:2px solid var(--paper);overflow:hidden;cursor:zoom-in}
.masonry-item img{width:100%;height:auto;display:block;filter:var(--img-rest);transition:filter .6s ease,transform .5s ease}
.masonry-item:hover img{filter:var(--img-hover);transform:scale(1.02)}
/* Project-screenshot galleries (full-page site captures, wildly varying raw
   heights) get a capped crop so the grid reads as neat tiles rather than a
   few towering columns next to short ones — the personal photo archive's
   masonry (true variable-aspect photos) is untouched. */
.masonry-shots .masonry-item img{max-height:420px;object-fit:cover;object-position:top}

/* legacy gallery grid still used where a uniform crop genuinely reads better */
.gallery-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:1rem}
@media(min-width:768px){.gallery-grid{grid-template-columns:repeat(3,1fr)}}
.gallery-grid img{width:100%;height:220px;object-fit:cover;object-position:top;filter:var(--img-rest);border:2px solid var(--paper);cursor:zoom-in;transition:filter .6s ease,transform .4s ease}
.gallery-grid img:hover{filter:var(--img-hover);transform:scale(1.03)}

/* Project hero — a bold, clean fixed rectangle (crop is fine here, this is
   a case-study poster shot, not a personal photo with faces to protect). */
.hero-media{max-height:720px}
.hero-media .image-frame{height:clamp(320px,62vw,680px)}
@media(min-width:768px){.hero-media .image-frame{height:680px}}
.hero-media .image-frame .frame-box{background:var(--ink)}
.hero-media .image-frame .frame-box img{width:100%;height:100%;max-width:none;max-height:none;object-fit:cover;object-position:top}

/* VIDEO (testimonial + project video) — full frame always visible, never
   force-cropped to fit a box; the frame sizes to the video's own ratio. */
.video-frame{border:2px solid var(--paper);background:var(--base-300);display:flex;justify-content:center;max-width:640px;margin:0 auto}
.video-frame video{width:100%;height:auto;max-height:80vh;object-fit:contain}
.project-video{border:2px solid var(--paper);background:var(--base-300);display:flex;justify-content:center}
.project-video video{width:100%;height:auto;max-height:75vh;object-fit:contain}

/* MAGIC / TESTIMONIALS */
.magic-hero{max-width:380px;margin:0 auto}
.magic-hero .image-frame .frame-box{border:none;padding:0;height:auto;background:transparent}
.magic-hero .image-frame .frame-box img{height:auto;object-fit:contain}
.split-reverse{flex-direction:column}
@media(min-width:768px){.split-reverse{flex-direction:row-reverse}}
/* IN THEIR WORDS — a stack of sticky cards. Each card pins a little lower
   than the one before (so the edges peek out like a deck); script.js lights
   the quote up word by word and tucks earlier cards back as new ones land. */
.words-section{align-items:center}
.words-sub{color:var(--muted);max-width:34rem;margin-top:-.5rem}
.words-stack{width:100%;max-width:58rem;position:relative;padding-bottom:4vh}
.word-card{position:sticky;top:calc(96px + var(--i) * 14px);margin:0 0 16vh;padding:clamp(1.6rem,4vw,3rem);border:2px solid var(--paper);background:var(--ink);display:flex;flex-direction:column;gap:1.4rem;min-height:min(62vh,34rem);justify-content:center;transform-origin:50% 0;box-shadow:0 -18px 40px rgba(0,0,0,.35);will-change:transform}
.word-card:last-child{margin-bottom:0}
.word-mark{font-family:var(--grunge);font-size:clamp(4rem,9vw,7rem);line-height:.5;height:.45em;color:var(--paper);opacity:.9}
.word-quote{margin:0;font-family:var(--grunge);text-transform:uppercase;font-size:clamp(1.45rem,3.3vw,2.6rem);line-height:1.12;letter-spacing:.005em;color:var(--paper)}
.word-quote .ww{transition:opacity .15s linear}
.words-live .word-quote .ww{opacity:.35}
.word-cite{display:flex;align-items:center;gap:.85rem;padding-top:1.1rem;border-top:1px solid color-mix(in oklch,var(--paper) 18%,transparent)}
.word-avatar{display:grid;place-items:center;width:2.6rem;height:2.6rem;border:2px solid var(--paper);border-radius:50%;font-family:var(--grunge);font-size:1.3rem;flex-shrink:0}
.word-who{display:flex;flex-direction:column;gap:.15rem;min-width:0}
.word-who b{font-family:var(--mono);font-size:.9rem;letter-spacing:.04em;text-transform:uppercase}
.word-who small{font-family:var(--mono);font-size:.75rem;color:var(--muted)}
.word-n{margin-left:auto;white-space:nowrap;flex-shrink:0;font-family:var(--mono);font-size:.7rem;letter-spacing:.14em;color:var(--muted)}
@media(max-width:599px){.word-card{top:calc(78px + var(--i) * 10px);margin-bottom:10vh;min-height:0}}

/* LIGHTBOX */
.lightbox{position:fixed;inset:0;z-index:200;background:rgba(11,9,8,.94);display:none;align-items:center;justify-content:center;padding:5vw;cursor:zoom-out}
.lightbox.open{display:flex}
.lightbox img{max-width:100%;max-height:88vh;object-fit:contain;border:2px solid var(--paper);filter:none}
.lightbox .lightbox-close{position:absolute;top:24px;right:24px;min-height:44px;min-width:44px}
.lightbox .lightbox-close svg path{fill:var(--paper)}

/* GRAIN CANVAS */
#grain-canvas{position:fixed;inset:0;z-index:2;pointer-events:none;opacity:.5;mix-blend-mode:overlay}

/* ============ PRELOADER ============
   UplinkLoader (ThreeUI) embedded verbatim in its own iframe/document so its
   self-contained styles/fonts/shaders never collide with the site's own.
   This wrapper only owns sizing + the fade-to-reveal transition. */
#preloader{position:fixed;inset:0;z-index:500;background:#000}
html.no-preloader #preloader{display:none}
#preloader.done{pointer-events:none}
#preloader-frame{position:absolute;inset:0;display:block;width:100%;height:100%;border:0}

/* ============ LANDING GATE ============
   A two-way question shown once per session, FIRST — visible from the very
   first paint (default-on CSS, not a JS-added class) so nothing underneath
   it — preloader included — is ever visible before the visitor answers.
   html.gate-skip (set synchronously by the inline script in <head>, before
   this element is even parsed, when sessionStorage already has odGateSeen)
   hides it instantly for repeat visits this session, with zero flash.
   "No" swaps the question for a creative one-more-try persuasion panel,
   then — if they still want to leave — a short optional feedback form
   before the tab attempts to close itself. See script.js for all of that
   plus the mailto: submit, since this is a static site with no backend. */
#gate{position:fixed;inset:0;z-index:600;background:var(--ink) url("/assets/theme/bg.jpg") center top/cover no-repeat;display:flex;align-items:center;justify-content:center;padding:2rem var(--canvas-pad);opacity:1;visibility:visible;pointer-events:auto;transition:opacity .5s ease;overflow-y:auto}
#gate:before{content:"";position:absolute;inset:0;pointer-events:none;opacity:.15;mix-blend-mode:overlay;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 baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E")}
html.gate-skip #gate{display:none}
#gate.done{opacity:0;visibility:hidden;pointer-events:none}
.gate-inner{position:relative;max-width:38rem;width:100%;text-align:center;display:flex;flex-direction:column;align-items:center;gap:1.5rem}
/* Short laptop screens: keep the whole question + buttons in one view. */
@media (max-height:760px){.gate-inner{gap:1rem}.gate-inner .h2{font-size:clamp(2.4rem,9.5vh,4rem)}}
.gate-question{display:flex;flex-direction:column;align-items:center;gap:1rem}
#gatePersuade{display:none}
#gatePersuade.show{display:flex}
.gate-actions{display:flex;gap:1rem;justify-content:center;flex-wrap:wrap}
.gate-feedback{display:none;flex-direction:column;align-items:center;gap:1.25rem;width:100%;max-width:30rem}
.gate-feedback.show{display:flex}
.gate-feedback textarea,.gate-feedback input{width:100%;background:transparent;border:2px solid var(--paper);color:var(--paper);padding:.8rem 1rem;font-family:var(--mono);font-size:1rem}
.gate-feedback textarea{min-height:110px;resize:vertical}
.gate-feedback textarea:focus,.gate-feedback input:focus{outline:2px solid var(--muted);outline-offset:2px}
.gate-feedback::placeholder{color:var(--muted)}

/* ============ MARQUEE ============
   Two full-bleed bands crossing in a shallow X: paper band (-3deg) running
   left on top, ink band (+2.5deg) running right underneath. Fixed paper/ink
   tokens so it reads the same in light or dark theme. Motion is driven by
   script.js (speed + direction follow the scroll); the keyframes below are
   only the fallback when GSAP isn't available. */
.marquee{position:relative;width:100vw;margin-left:calc(50% - 50vw);height:clamp(7.5rem,15vw,10.5rem);margin-block:2rem;overflow:hidden;display:grid;place-items:center}
.mq-band{grid-area:1/1;width:110vw;overflow:hidden;padding:.7rem 0;border-block:2px solid var(--ink-fixed)}
.mq-a{background:var(--paper-fixed);transform:rotate(-3deg);z-index:2;box-shadow:0 10px 30px rgba(0,0,0,.35)}
.mq-b{background:var(--ink-fixed);border-color:var(--paper-fixed);transform:rotate(2.5deg);z-index:1}
/* Narrow screens: steeper crossing so the X still reads, and the ink band
   gets a faint paper edge so it doesn't vanish into the dark page. */
@media (max-width:767px){
    .marquee{height:9.5rem}
    .mq-band{width:140vw}
    .mq-a{transform:rotate(-7deg)}
    .mq-b{transform:rotate(6deg);box-shadow:0 0 0 1px rgba(238,234,224,.25)}
}
.mq-track{display:flex;align-items:center;width:max-content;will-change:transform;animation:mq-left 22s linear infinite}
.mq-b .mq-track{animation-name:mq-right}
.marquee.is-driven .mq-track{animation:none}
.mq-item{font-family:var(--grunge);text-transform:uppercase;font-size:clamp(1.25rem,3.4vw,2.3rem);line-height:1;letter-spacing:.02em;white-space:nowrap;padding:0 1.1rem;color:var(--ink-fixed)}
.mq-b .mq-item{color:var(--paper-fixed)}
.mq-item.mq-alt{font-family:var(--mono);font-weight:800;font-size:clamp(.85rem,1.9vw,1.25rem);letter-spacing:.14em}
.mq-star{display:inline-block;font-size:clamp(.9rem,2vw,1.3rem);color:var(--ink-fixed);animation:mq-spin 6s linear infinite}
.mq-b .mq-star{color:var(--paper-fixed);animation-direction:reverse}
@keyframes mq-left{from{transform:translateX(0)}to{transform:translateX(-50%)}}
@keyframes mq-right{from{transform:translateX(-50%)}to{transform:translateX(0)}}
@keyframes mq-spin{to{transform:rotate(360deg)}}

/* ============ PHOTO SLIDER ============
   One horizontal, snap-scrolling strip per personal-photo subfolder. Native
   CSS scroll-snap handles touch/trackpad drag; the prev/next buttons just
   nudge scrollLeft by one slide (see script.js). */
.photo-slider{width:100%;margin:1rem 0;display:flex;flex-direction:column;gap:1rem}
.slider-head{display:flex;align-items:center;justify-content:space-between;gap:1rem}
.slider-controls{display:flex;gap:.5rem;flex-shrink:0}
.slider-btn{border:2px solid var(--paper);background:transparent;color:var(--paper);width:40px;height:40px;display:grid;place-items:center;cursor:pointer;font-size:1.1rem;flex-shrink:0;transition:background .2s,color .2s}
.slider-btn:hover{background:var(--paper);color:var(--ink)}
.slider-track{display:flex;gap:1rem;overflow-x:auto;scroll-snap-type:x mandatory;padding-bottom:.5rem;scrollbar-width:none}
.slider-track::-webkit-scrollbar{display:none}
.slider-slide{flex:0 0 auto;width:min(78vw,340px);aspect-ratio:3/4;scroll-snap-align:start;border:2px solid var(--paper);overflow:hidden;cursor:zoom-in}
.slider-slide img{width:100%;height:100%;object-fit:cover;object-position:top;filter:var(--img-rest);transition:filter .6s ease}
.slider-slide:hover img{filter:var(--img-hover)}

/* COOKIE BANNER */
#cookie-banner{position:fixed;left:1rem;right:1rem;bottom:1rem;z-index:300;max-width:34rem;margin:0 auto;display:flex;flex-wrap:wrap;align-items:center;gap:1rem;justify-content:space-between;border:2px solid var(--paper);background:var(--ink);padding:1rem 1.25rem;opacity:0;transform:translateY(16px);pointer-events:none;transition:opacity .4s ease,transform .4s ease}
#cookie-banner.show{opacity:1;transform:translateY(0);pointer-events:auto}
#cookie-banner p{margin:0;flex:1 1 16rem}
.cookie-actions{display:flex;align-items:center;gap:.75rem;flex-shrink:0}
.cookie-accept{font-family:var(--grunge);text-transform:uppercase;letter-spacing:.02em;border:2px solid var(--paper);padding:.4rem 1rem;min-height:40px;transition:background .2s,color .2s}

/* ============ EXIT-INTENT POPUP ============
   Comical "drop your idea" prompt, armed only once the preloader clears and
   triggered when the cursor leaves out the top of the viewport. Shares the
   gate's button/form styling, dressed as a centered card over a dim scrim. */
#exit-popup{position:fixed;inset:0;z-index:550;background:color-mix(in oklch,var(--ink) 80%,transparent);display:flex;align-items:center;justify-content:center;padding:2rem var(--canvas-pad);opacity:0;visibility:hidden;pointer-events:none;transition:opacity .4s ease}
#exit-popup.show{opacity:1;visibility:visible;pointer-events:auto}
#exit-popup.done{pointer-events:none}
.exit-inner{position:relative;max-width:44rem;width:100%;max-height:90vh;overflow-y:auto;text-align:center;display:flex;flex-direction:column;align-items:center;gap:1.5rem;background:var(--ink);border:2px solid var(--paper);padding:3rem 2.5rem}
.exit-close{position:absolute;top:.75rem;right:.9rem;font-size:1.6rem;line-height:1;background:none;border:0;color:var(--paper);cursor:pointer;padding:.25rem .5rem}
.exit-question{display:flex;flex-direction:column;align-items:center;gap:1rem}
.cookie-accept:hover{background:var(--paper);color:var(--ink)}
.cookie-close{font-size:1.4rem;line-height:1;padding:.2rem .5rem;color:var(--muted)}
.cookie-close:hover{color:var(--paper)}

/* LEGAL PAGES */
.legal-link{text-decoration:underline;text-underline-offset:2px}
.legal-link:hover{color:var(--muted)}
code{font-family:var(--mono);background:var(--base-300);padding:.1em .4em;font-size:.9em}

/* TAGS */
.tag-list{display:flex;flex-wrap:wrap;justify-content:center;gap:.6rem}
.tag-list span{border:2px solid var(--paper);padding:.5rem .9rem;font-size:.8rem;text-transform:uppercase;letter-spacing:.04em}

/* CONTACT */
.contact-grid{display:flex;flex-direction:column;gap:1.5rem;flex-wrap:wrap}
@media(min-width:768px){.contact-grid{flex-direction:row}}
.contact-item{border:2px solid var(--paper);padding:1.25rem;display:flex;flex-direction:column;gap:1rem;flex:1 1 200px;min-width:0}
.contact-item .row{display:flex;justify-content:space-between;align-items:center;gap:.75rem}
.contact-item .row img{width:36px;height:20px;flex-shrink:0}
.contact-item .divider{height:1px;background:var(--paper);width:100%}
.contact-item a,.contact-item p{overflow-wrap:anywhere}

/* CREDENTIALS */
.credential-single{max-width:420px;margin:0 auto;display:flex;flex-direction:column;gap:1.5rem;align-items:center}
.credential-single .image-frame{width:100%}

/* MY JOURNEY (about page) — guillaumezhu.com-style letter narrative; the
   motion itself is in script.js. */
/* Full-bleed solid --ink band (theme-aware: black in dark, paper-white in
   light). Fallback (no JS): title + phrases simply stack as text. */
.journey{position:relative;background:var(--ink);width:100vw;margin-left:calc(50% - 50vw);text-align:center;color:var(--paper)}
.journey-title{min-height:100vh;min-height:100svh;display:flex;align-items:center;justify-content:center;padding:0 var(--canvas-pad)}
.journey-heading{font-family:var(--grunge);text-transform:uppercase;font-weight:400;line-height:.9;margin:0;font-size:clamp(3.4rem,13vw,11rem);letter-spacing:-.01em}
.journey-stage{display:flex;flex-direction:column;align-items:center;gap:2.5rem;padding:4rem var(--canvas-pad) 8rem}
.journey-line{margin:0}
.journey-label{font-family:var(--grunge);text-transform:uppercase;font-size:clamp(3rem,11vw,9rem);line-height:.9}
.journey-big{font-family:var(--grunge);text-transform:uppercase;font-size:clamp(2.6rem,9vw,7.5rem);line-height:.92;margin:0;max-width:14ch;margin-inline:auto}
.journey-sub{font-family:var(--mono);font-size:clamp(.85rem,1.6vw,1.05rem);line-height:1.7;color:var(--muted);max-width:34rem;margin:1.4rem auto 0}
/* Scroll-driven mode (JS adds .is-live): a tall runway with a sticky
   viewport-sized stage; every line is stacked dead-centre and script.js
   moves its letters in/out from the scroll position. */
.journey.is-live .journey-runway{height:calc(var(--jl-count,6) * 85vh + 100vh)}
.journey.is-live .journey-stage{position:sticky;top:0;height:100vh;height:100svh;padding:0 var(--canvas-pad);display:block;overflow:hidden}
.journey.is-live .journey-line{position:absolute;left:var(--canvas-pad);right:var(--canvas-pad);top:50%;transform:translateY(-50%)}
.journey .jw{display:inline-block;white-space:nowrap}
.journey .jc{display:inline-block;will-change:transform,opacity}
.journey.is-live .journey-sub{transition:opacity .4s ease,transform .4s ease}
/* CTA BAND (before footer) — an oversized heading that settles into place
   (rotate + scale ease out) as it scrolls into view. */
.cta-band{padding:4rem 0;border-top:1px solid rgba(238,238,230,.15);position:relative;overflow:hidden}
.cta-band > .container{position:relative;z-index:1}
/* The 3D hexagon is a backdrop, so it sits well back: faint, and masked to
   fade out toward the centre where the heading and text are. */
.cta-3d{position:absolute;inset:0;pointer-events:none;opacity:.32;-webkit-mask-image:radial-gradient(ellipse 60% 55% at 50% 50%,transparent 0%,#000 75%);mask-image:radial-gradient(ellipse 60% 55% at 50% 50%,transparent 0%,#000 75%)}
.cta-3d canvas{display:block;width:100%;height:100%}
.cta-rotate{will-change:transform}

/* FOOTER */
footer{padding:4rem 0 2rem;position:relative;z-index:20}
.footer-logo{display:flex;align-items:center;justify-content:center;gap:.6rem;margin-bottom:3rem;font-family:var(--grunge);font-size:1.3rem;text-transform:uppercase;letter-spacing:.02em}
.footer-logo img{height:28px;width:auto;display:block}
@media(min-width:768px){.footer-logo{font-size:1.6rem;gap:.8rem}.footer-logo img{height:40px}}
[data-theme="light"] .footer-logo img{filter:invert(1)}
.footer-cols{display:flex;flex-direction:column;gap:2.5rem;text-align:center}
@media(min-width:768px){.footer-cols{flex-direction:row}.footer-cols>div{flex:1;text-align:left}.footer-cols>div:last-child{text-align:right}}
footer .h6{margin-bottom:1.2rem}
footer li{margin-bottom:.6rem}
footer li a:hover{color:var(--muted)}
.footer-bottom{text-align:center;margin-top:3rem}
.footer-bottom p{margin:.3rem 0;font-size:.85rem}
.footer-bottom p.t-xsm{font-size:.7rem;color:var(--muted)}

/* ============ MOBILE QA ============ */
@media(max-width:599px){
    .wrap{padding-left:20px;padding-right:20px}
    .hero{min-height:auto;padding-top:1rem}
    .work-grid{gap:3rem}
    .contact-item{flex-basis:100%}
    .masonry{columns:2 140px}
    .accordion-trigger{gap:.5rem}
    .exit-inner{padding:2.5rem 1.25rem}
    .gate-actions{gap:.6rem}
    #cookie-banner{left:.6rem;right:.6rem;bottom:.6rem;padding:.7rem .85rem;gap:.5rem}
    #cookie-banner{flex-wrap:nowrap;align-items:center}
    #cookie-banner p{flex:1 1 auto;font-size:.68rem;line-height:1.45}
    .cookie-actions{gap:.4rem}
    .cookie-accept{font-size:.85rem;padding:.25rem .6rem;min-height:32px}
    .footer-bottom p.t-xsm{font-size:.62rem}
    .footer-bottom p{font-size:.75rem}
}
html,body{max-width:100%;overflow-x:clip}

/* Respect reduced-motion: kill scroll-driven/parallax movement, keep content instantly visible */
@media (prefers-reduced-motion: reduce){
    *{animation-duration:.01ms!important;animation-iteration-count:1!important;transition-duration:.01ms!important;scroll-behavior:auto!important}
    #preloader{display:none!important}
    .mq-track,.mq-star{animation:none!important}
}

/* ============ BARCODE MARK (taps through to WhatsApp) ============ */
.barcode-link{display:block;line-height:0;flex-shrink:0;transition:opacity .2s ease}
.barcode-link:hover{opacity:.7}
.image-frame .barcode-link img.barcode{width:100px;opacity:.85}
.bottom-mark .barcode-link img.barcode{width:110px;opacity:.85}
[data-theme="light"] img.barcode{filter:invert(1)}

/* ============ LANDING: LAGOS CLOCK + HEADLINE ============ */
.gate-clock{position:absolute;top:calc(1.5rem + 16px);transform:translateY(-50%);left:var(--canvas-pad);z-index:1;display:flex;align-items:center;gap:.5rem;font-family:var(--mono);font-size:.7rem;letter-spacing:.1em;text-transform:uppercase;color:var(--paper)}
.ng-flag{width:21px;height:14px;border:1px solid rgba(238,234,224,.5);border-radius:2px;flex-shrink:0}
.gate-time{font-weight:700;font-variant-numeric:tabular-nums;padding-left:.5rem;border-left:1px solid rgba(238,234,224,.35)}
@media (max-width:420px){.gate-clock{font-size:.58rem;letter-spacing:.05em;gap:.4rem}.gate-time{padding-left:.4rem}}
.gate-inner{max-width:min(60rem,100%)}
.gate-title{font-family:var(--grunge);text-transform:uppercase;font-weight:400;line-height:.88;letter-spacing:-.01em;margin:0;color:var(--paper);font-size:clamp(3.6rem,13vw,9.5rem);text-wrap:balance}
@media (max-height:760px){.gate-title{font-size:clamp(3.2rem,15.5vh,7.5rem)}}
/* Phones: smaller headline and room at the top so the Lagos clock row and
   language pill have breathing space above the question. */
@media (max-width:600px){
    #gate{align-items:flex-start;padding-top:5.5rem}
    .gate-inner{gap:1.1rem;margin-block:auto}
    .gate-title{font-size:clamp(2.5rem,12vw,3.4rem);line-height:.93}
    .gate-inner .t-sm{font-size:.85rem;line-height:1.6}
}

/* ============ NAME ENTRY (dictionary-style pronunciation) ============
   Set in the display face used on the project-card labels, small and
   uppercase, so it reads as part of the same visual family as the name. */
.name-entry{margin-top:1.1rem;max-width:36rem;padding-left:1rem;border-left:2px solid var(--paper);font-family:var(--grunge);text-transform:uppercase;letter-spacing:.02em;color:var(--paper)}
.name-entry p{margin:0}
.name-head{display:flex;flex-wrap:wrap;align-items:baseline;gap:.2rem .7rem;font-size:1.35rem;line-height:1.1}
.name-phon{color:var(--muted);text-transform:none}
.name-pos{font-style:italic;font-size:1.1rem;color:var(--muted)}
.name-def{margin-top:.4rem!important;font-size:1.15rem;line-height:1.25}
.name-def b{margin-right:.3rem;font-weight:400}
.name-origin{margin-top:.35rem!important;font-size:.95rem;color:var(--muted)}
.name-label{font-family:var(--mono);font-size:.62em;font-weight:700;letter-spacing:.14em;text-transform:uppercase;color:var(--paper);margin-right:.35rem;vertical-align:.12em}
/* Phones: the whole entry steps down a size so it stays a neat footnote. */
@media(max-width:599px){
    .name-entry{margin-top:.8rem;padding-left:.75rem}
    .name-head{font-size:1.02rem;gap:.15rem .5rem}
    .name-pos{font-size:.85rem}
    .name-def{font-size:.9rem}
    .name-origin{font-size:.74rem}
}
