/* ==========================================================================
   Styles. Colours come from content.js (theme) via CSS variables, so you
   normally don't need to touch this file. Fonts are set in :root below.
   ========================================================================== */
@font-face { font-family: "Newsreader"; src: url("../assets/fonts/newsreader-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Newsreader"; src: url("../assets/fonts/newsreader-latin-500-normal.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Newsreader"; src: url("../assets/fonts/newsreader-latin-600-normal.woff2") format("woff2"); font-weight: 600 900; font-display: swap; }
:root {
  --ink: #0d0d0d;
  --paper: #f6f3ec;
  --c0: #c6ff00; --c1: #ff3ea5; --c2: #00e0ff; --c3: #ff8a00; --c4: #a77bff;
  /* techno / Y2K cyber type, served from assets/fonts (no Google request) */
  /* one plain serif for everything that isn't a framed title: flat, Times-like, a touch heavy but thin-stroked */
  --display: "Newsreader", "Times New Roman", Times, serif;
  --body: "Newsreader", "Times New Roman", Times, serif;
  --chrome: linear-gradient(135deg, #fff 0%, #cfd3da 30%, #fdfdfd 50%, #a9aeb7 70%, #f2f2f2 100%);
  /* matte white plastic, like an iPod's front */
  --plastic: linear-gradient(180deg, #fdfdfb 0%, #f3f2ee 55%, #e9e8e3 100%);
  --gutter: clamp(16px, 4vw, 48px);
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; background: var(--ink); color: var(--ink);
  font-family: var(--body); -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
body.no-scroll { overflow: hidden; }
button { font: inherit; color: inherit; cursor: pointer; }
a { color: inherit; }
img { display: block; max-width: 100%; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid var(--c1); outline-offset: 3px; }

/* ---------- top bar ---------- */
.topbar {
  position: fixed; inset: 0 0 auto 0; z-index: 50;
  display: flex; align-items: center; gap: 24px;
  padding: 14px var(--gutter); pointer-events: none;
}
.topbar > * { pointer-events: auto; }
.logo {
  font-family: var(--display); font-size: 15px; text-decoration: none; color: var(--paper);
  background: var(--ink); padding: 8px 14px; border-radius: 999px; letter-spacing: .02em;
}
.toplinks { display: flex; gap: 6px; margin-left: auto; }
.toplinks a {
  text-decoration: none; font-weight: 700; font-size: 14px; padding: 8px 14px; border-radius: 999px;
  background: var(--ink); color: var(--paper); transition: background .2s, color .2s, transform .2s;
}
.toplinks a:hover { background: var(--paper); color: var(--ink); transform: translateY(-2px) rotate(-2deg); }
.ipod-btn {
  width: 44px; height: 64px; border: 0; border-radius: 10px; padding: 6px;
  background: var(--plastic); box-shadow: 0 4px 14px rgba(0,0,0,.22), inset 0 0 0 1px rgba(0,0,0,.08);
  display: grid; grid-template-rows: 22px 1fr; place-items: center; gap: 4px; transition: transform .2s;
}
.ipod-btn:hover { transform: rotate(-8deg) scale(1.06); }
.ipod-btn__screen { width: 100%; height: 22px; border-radius: 3px; background: linear-gradient(#b8d8ff, #6aa7ff); }
.ipod-btn__wheel { width: 24px; height: 24px; border-radius: 50%; background: radial-gradient(circle, #fbfbf9 30%, #e2e1dc 32%); }
@media (max-width: 760px) { .toplinks { display: none; } .ipod-btn { margin-left: auto; } }

/* ---------- shared section bits ---------- */
section, footer { position: relative; }
.splash-bg { position: absolute; inset: 0; width: 100%; height: 100%; display: block; z-index: 0; }
.sec-head { position: relative; z-index: 2; padding: 110px var(--gutter) 0; display: flex; flex-wrap: wrap; align-items: end; gap: 16px 32px; }
.sec-title {
  font-family: var(--display); font-weight: 600; margin: 0; line-height: .85;
  font-size: clamp(28px, 8.3vw, 118px); letter-spacing: -.01em; text-transform: uppercase;
}
.sec-sub { margin: 0 0 10px; font-weight: 500; font-size: 16px; }
.reveal { opacity: 0; transform: translateY(40px) skewY(3deg); transition: opacity .7s, transform .9s cubic-bezier(.2,.9,.2,1.2); }
.reveal.in { opacity: 1; transform: none; }

/* ---------- hero ---------- */
.hero { min-height: 100svh; overflow: hidden; display: flex; align-items: center; cursor: crosshair; }
.hero__viz { position: absolute; z-index: 1; pointer-events: none; image-rendering: pixelated; }
.hero__dancer { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 1; pointer-events: none; }
.hero__text { position: relative; z-index: 2; padding: 0 var(--gutter); max-width: 62%; }
.hero__kicker { font-weight: 700; letter-spacing: .3em; text-transform: uppercase; font-size: 13px; margin: 0 0 12px; }
.hero__name {
  font-family: var(--display); font-weight: 600; margin: 0; line-height: .88; letter-spacing: -.01em;
  font-size: clamp(56px, 12vw, 200px); text-transform: uppercase; word-break: break-word;
}
.hero__words { font-family: var(--display); font-size: clamp(22px, 4vw, 54px); margin-top: 18px; height: 1.1em; overflow: hidden; }
.hero__words span { display: inline-block; background: var(--ink); color: var(--paper); padding: 0 .25em; }
.hero__words span.pop { animation: pop .5s cubic-bezier(.2,1.6,.4,1); }
@keyframes pop { from { transform: translateY(110%) rotate(6deg); } to { transform: none; } }
.hero__tagline { font-weight: 500; font-size: 18px; margin: 18px 0 0; }
.hero__tagline:empty { display: none; }
/* the big name's letters sit a hair right of their box: pull them in so they line up with PORTFOLIO */
.hero__scroll {
  position: absolute; z-index: 2; left: var(--gutter); bottom: 24px; font-weight: 700; text-decoration: none;
  font-size: 13px; letter-spacing: .2em; text-transform: uppercase; animation: bob 1.6s ease-in-out infinite;
}
@keyframes bob { 50% { transform: translateY(6px); } }
@media (max-width: 720px) {
  .hero { align-items: flex-start; }
  .hero__text { max-width: 100%; padding-top: 110px; }
}

/* ---------- marquee ---------- */
.marquee { background: var(--ink); color: var(--paper); overflow: hidden; border-block: 3px solid var(--paper); }
.marquee__track { will-change: transform;
  white-space: nowrap; font-family: var(--display); font-size: 22px; padding: 12px 0;
  display: inline-block; animation: marquee 30s linear infinite;
}
@keyframes marquee { to { transform: translateX(-50%); } }

/* ---------- work: one carousel per skill ---------- */
.work { background: var(--paper); color: var(--ink); }
.work-nav { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 10px; }
.work-nav .series-tab { text-decoration: none; color: inherit; }
.work__list { margin-top: 28px; }
.wsec { background: var(--wbg); color: var(--sec-ink, var(--ink)); padding: 84px 0 46px; overflow: hidden; scroll-margin-top: 0;
  content-visibility: auto; contain-intrinsic-size: auto 760px; }   /* off-screen sections skip drawing */
.wsec__flow { margin-top: 22px; }
.wsec + .wsec { border-top: 3px solid var(--ink); }
.wsec__head { position: relative; z-index: 3; padding: 0 var(--gutter); display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 22px; }
.wsec__title { font-family: var(--display); font-weight: 600; margin: 0; text-transform: uppercase; line-height: .9; font-size: clamp(30px, 6vw, 76px); }
.wsec__blurb { margin: 0; font-size: 16px; font-weight: 500; }
.wsec__blurb b { opacity: .6; font-weight: 700; margin-left: 4px; }
.wsec .coverflow { height: clamp(280px, 44vh, 460px); }
.wsec .cf-item { width: clamp(150px, min(26vw, 30vh), 290px); }
.wsec .cf-caption { padding-top: 34px; }
.wsec .cf-arrow { background: var(--sec-ink, var(--ink)); color: var(--wbg); }
.wsec .cf-item.is-active { box-shadow: 0 0 0 4px var(--sec-ink, var(--ink)), 0 30px 60px rgba(0,0,0,.35); }
.lb-poem { max-height: 32svh; overflow: auto; text-align: left; justify-self: center; width: min(560px, 100%); font-size: 15px; line-height: 1.55;
  background: rgba(255,255,255,.06); padding: 12px 16px; border-radius: 12px; margin-top: 4px; overscroll-behavior: contain; touch-action: pan-y; }
.series-tabs { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 10px; }
.series-tab {
  border: 2px solid var(--ink); background: var(--paper); color: var(--ink); border-radius: 999px;
  padding: 8px 16px 8px 8px; font-weight: 700; display: flex; align-items: center; gap: 8px;
  transition: transform .2s, background .2s, color .2s;
}
.series-tab i { width: 22px; height: 22px; border-radius: 50%; border: 2px solid var(--ink); }
.series-tab:hover { transform: translateY(-3px) rotate(-2deg); }
.series-tab.on { background: var(--ink); color: var(--paper); }
.series-info { padding: 24px var(--gutter) 0; max-width: 720px; }
.series-info__title { font-family: var(--display); font-weight: 600; font-size: clamp(20px, 3vw, 32px); margin: 0 0 6px; }
.series-info__blurb { margin: 0; font-size: 17px; }

.coverflow { height: clamp(320px, 52vh, 520px); perspective: 1100px; touch-action: pan-y; user-select: none; outline: none; }
.coverflow__stage { position: relative; width: 100%; height: 100%; transform-style: preserve-3d; transition: opacity .35s, transform .35s; }
.coverflow__stage.out { opacity: 0; transform: scale(.85) translateY(30px); }
.coverflow__stage.in { animation: cfIn .6s cubic-bezier(.2,1.4,.4,1); }
@keyframes cfIn { from { opacity: 0; transform: scale(1.15) translateY(-20px); } }
.cf-item {
  position: absolute; left: 50%; top: 50%; width: clamp(180px, 26vw, 300px); aspect-ratio: 4 / 5;
  padding: 0; border: 0; background: var(--ink); border-radius: 4px; overflow: visible;
  transition: transform .55s cubic-bezier(.2,.8,.2,1), opacity .4s;
  -webkit-box-reflect: below 6px linear-gradient(transparent 62%, rgba(255,255,255,.28));
  box-shadow: 0 20px 40px rgba(0,0,0,.3);
}
.cf-item.far { -webkit-box-reflect: none; box-shadow: none; }
.cf-item img { width: 100%; height: 100%; object-fit: cover; border-radius: 4px; pointer-events: none; }
.cf-item.is-active { cursor: zoom-in; box-shadow: 0 0 0 4px var(--ink), 0 30px 60px rgba(0,0,0,.35); }
.coverflow__stage.dragging .cf-item { transition: none; }
.cf-caption { display: flex; align-items: center; justify-content: center; gap: 18px; padding: 50px var(--gutter) 0; }
.cf-caption__text { text-align: center; min-width: 0; display: grid; gap: 4px; }
.cf-caption__text strong { font-family: var(--display); font-weight: 600; font-size: clamp(18px, 2.4vw, 26px); }
.cf-caption__text span { font-size: 14px; font-weight: 500; }
.cf-arrow {
  border: 0; width: 52px; height: 52px; border-radius: 50%; background: var(--ink); color: var(--paper);
  font-size: 13px; flex: none; transition: transform .15s;
}
.cf-arrow:active { transform: scale(.9); }

/* ---------- videos (auto-sorted social posts) ---------- */
.videos { overflow: hidden; color: var(--sec-ink, var(--ink)); padding-bottom: 70px; }
.videos > *:not(canvas) { position: relative; z-index: 2; }
.series-tab small { font-size: 11px; opacity: .65; }
.videos__meta { padding: 14px var(--gutter) 0; margin: 0; font-size: 13px; font-weight: 700; letter-spacing: .04em; }
.vrow-wrap { display: flex; align-items: center; gap: 12px; padding: 26px var(--gutter) 0; }
.vrow {
  flex: 1; min-width: 0; display: grid; grid-auto-flow: column; grid-auto-columns: clamp(160px, 18vw, 220px); gap: 20px;
  overflow-x: auto; scroll-snap-type: x mandatory; padding: 6px 4px 22px; scrollbar-width: thin; transition: opacity .3s, transform .3s;
}
.vrow.out { opacity: 0; transform: translateX(-30px); }
.vcard {
  scroll-snap-align: start; border: 3px solid var(--ink); border-radius: 18px; background: var(--paper); color: var(--ink);
  padding: 8px 8px 12px; text-align: left; display: grid; gap: 4px; align-content: start; box-shadow: 6px 6px 0 var(--ink);
  animation: vIn .5s var(--d, 0ms) both cubic-bezier(.2,1.4,.4,1); transition: translate .2s, box-shadow .2s;
}
.vcard:hover { translate: -3px -5px; box-shadow: 10px 10px 0 var(--ink); }
@keyframes vIn { from { opacity: 0; transform: translateY(30px) rotate(3deg); } }
.vcard__img { position: relative; aspect-ratio: 9 / 16; max-width: 100%; border-radius: 12px; overflow: hidden; background: var(--ink); margin-bottom: 6px; }
.vcard__img img { width: 100%; height: 100%; object-fit: cover; }
.vcard__play {
  position: absolute; left: 50%; top: 50%; translate: -50% -50%; width: 54px; height: 54px; border-radius: 50%;
  display: grid; place-items: center; background: var(--paper); color: var(--ink); border: 3px solid var(--ink); font-size: 18px;
  transition: scale .2s;
}
.vcard:hover .vcard__play { scale: 1.15; }
.vcard strong { font-size: 14px; line-height: 1.25; overflow-wrap: anywhere; }
.vcard__meta { font-size: 12px; opacity: .7; font-weight: 500; }
.vcard__tags { font-size: 12px; font-weight: 700; color: var(--ink); overflow-wrap: anywhere; }
@media (max-width: 760px) { .vrow-arrow { display: none; } .vrow { grid-auto-columns: 62vw; } }

.lb-embed { border: 0; background: #000; border-radius: 12px; }
.lb-embed--tiktok { height: min(78vh, 760px); aspect-ratio: 9 / 16; max-width: 100%; }
.lb-embed--instagram { width: min(100%, 480px); height: min(78vh, 720px); background: #fff; }

/* ---------- sketchbooks ---------- */
.sketchbooks { background: var(--ink); color: var(--paper); padding-bottom: 30px; }
.sketchbooks .sec-sub { color: var(--c0); }
.shelf { position: relative; height: clamp(460px, 82svh, 900px); margin-top: 10px; }
.shelf__canvas { width: 100%; height: 100%; display: block; touch-action: pan-y; }
.shelf__label {
  position: absolute; left: 0; top: 0; pointer-events: none; z-index: 3;
  background: var(--paper); color: var(--ink); border: 3px solid var(--ink); border-radius: 14px;
  padding: 8px 14px; display: grid; gap: 2px; text-align: center; white-space: nowrap;
  box-shadow: 6px 6px 0 var(--ink);
}
.shelf__label strong { font-family: var(--display); font-weight: 600; font-size: 15px; }
.shelf__label span { font-size: 12px; font-weight: 500; }
.shelf.no3d { height: auto; }
.shelf.no3d canvas { display: none; }
.shelf__list { list-style: none; display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; padding: 0 var(--gutter); margin: 10px 0 0; }

.chip {
  display: inline-flex; align-items: center; gap: 8px; border: 2px solid currentColor; border-radius: 999px;
  padding: 6px 14px 6px 8px; background: transparent; font-weight: 700; font-size: 14px; text-decoration: none;
  transition: transform .15s, background .15s, color .15s;
}
.chip i { width: 16px; height: 16px; border-radius: 50%; }
.chip:hover { transform: translateY(-2px); background: var(--paper); color: var(--ink); }

/* ---------- extras ---------- */
.extras { overflow-x: clip; content-visibility: auto; contain-intrinsic-size: auto 1400px;
  background: var(--paper); padding-bottom: 100px;
  background-image: radial-gradient(rgba(0,0,0,.09) 1.5px, transparent 1.6px); background-size: 22px 22px;
}
.extras__grid {
  display: grid; gap: 28px; padding: 50px var(--gutter) 0;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 240px), 1fr));
}
.x-card {
  --card: var(--c0); text-decoration: none; display: block;
  position: relative; text-align: left; border: 3px solid var(--ink); border-radius: 22px; padding: 12px 12px 18px;
  background: var(--card); color: var(--ink); box-shadow: 8px 8px 0 var(--ink);
  rotate: var(--tilt); transition: rotate .3s cubic-bezier(.2,1.6,.4,1), translate .3s, box-shadow .3s;
}
.x-card.reveal.in { transform: none; }
button.x-card:hover, a.x-card:hover { rotate: 0deg; translate: -4px -6px; box-shadow: 14px 14px 0 var(--ink); }
.x-media { aspect-ratio: 1; border-radius: 14px; overflow: hidden; border: 3px solid var(--ink); background: var(--ink); margin-bottom: 12px; }
.x-media img { width: 100%; height: 100%; object-fit: cover; }
.x-media--glyph { display: grid; place-items: center; background: var(--chrome); }
.x-media--glyph span { font-size: 80px; font-family: var(--display); }
.x-media--feed { position: relative; }
.x-card--feed:hover .vcard__play { scale: 1.15; }
.x-card h3 { font-family: var(--display); font-weight: 600; font-size: 18px; margin: 0 4px 4px; }
.x-card p { margin: 0 4px; font-size: 14px; font-weight: 500; }
.x-card--text { background: var(--ink); color: var(--paper); padding: 24px; display: flex; flex-direction: column; justify-content: center; min-height: 200px; }
.x-card--text h3 { color: var(--card); font-size: 26px; }
.x-card--text p { font-size: 17px; line-height: 1.4; }
.x-badge {
  position: absolute; top: -14px; right: -12px; width: 40px; height: 40px; border-radius: 50%;
  display: grid; place-items: center; background: var(--paper); border: 3px solid var(--ink); color: var(--ink);
  font-size: 16px; font-weight: 700;
}

.x-embed { border-radius: 14px; overflow: hidden; border: 3px solid var(--ink); background: var(--ink); margin-bottom: 12px; }
.x-embed iframe { display: block; width: 100%; border: 0; }
.x-embed--tiktok iframe { aspect-ratio: 9 / 16; }
.x-embed--instagram iframe { height: 560px; background: #fff; }
.x-card a { color: inherit; font-weight: 700; }

/* social feeds under the extras grid */
.feeds { display: grid; gap: 28px; padding: 60px var(--gutter) 0; grid-template-columns: minmax(0, 1fr) minmax(0, 340px); align-items: start; }
.feed-card { border: 3px solid var(--ink); border-radius: 22px; padding: 18px; box-shadow: 8px 8px 0 var(--ink); background: var(--paper); color: var(--ink); min-width: 0; overflow: hidden; }
.feed-card__kicker { display: block; font-family: var(--display); font-size: 18px; margin-bottom: 12px; }
.feed-card--tt { background: var(--c2); }
.feed-card--tt blockquote { background: #fff; border-radius: 12px; min-height: 200px; }
.feed-card--ig { display: grid; gap: 8px; text-decoration: none; background: var(--c1); rotate: 2deg; transition: rotate .3s, translate .3s; }
.feed-card--ig:hover { rotate: 0deg; translate: -4px -6px; }
.feed-card--ig strong { font-family: var(--display); font-weight: 600; font-size: clamp(22px, 3vw, 30px); word-break: break-all; }
.feed-card--ig b { justify-self: start; background: var(--ink); color: var(--paper); padding: 10px 18px; border-radius: 999px; margin-top: 8px; }
@media (max-width: 760px) { .feeds { grid-template-columns: 1fr; } .feed-card--ig { rotate: 0deg; } }
.lb-link { color: var(--c0); font-weight: 700; justify-self: center; }

/* ---------- contact ---------- */
.contact { content-visibility: auto; contain-intrinsic-size: auto 800px; background: var(--c1); padding: 120px var(--gutter) 40px; text-align: center; overflow: hidden; }
.contact__big { font-family: var(--display); font-weight: 600; font-size: clamp(64px, 18vw, 260px); line-height: .85; margin: 0; letter-spacing: -.02em; }
.contact__slogan { font-family: var(--display); font-size: clamp(16px, 3.4vw, 34px); margin: 18px 0 0; letter-spacing: .02em; text-transform: lowercase; }
.contact__bio { max-width: 560px; margin: 28px auto 0; font-size: 18px; font-weight: 500; }
.contact__email {
  display: inline-block; margin-top: 26px; font-family: var(--display); font-size: clamp(16px, 3vw, 28px);
  background: var(--ink); color: var(--paper); padding: 14px 26px; border-radius: 999px; text-decoration: none;
  transition: transform .2s; word-break: break-all;
}
.contact__email:hover { transform: rotate(-3deg) scale(1.05); }
.contact__socials { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; margin-top: 22px; }
.contact__socials .chip:hover { background: var(--ink); color: var(--paper); }
.contact__fine { margin: 60px 0 0; font-size: 13px; font-weight: 500; }

/* ---------- iPod nav ---------- */
.ipod {
  position: fixed; inset: 0; z-index: 80; display: grid; place-items: center; align-content: center; gap: 16px;
}
/* only the dimmed, blurred backdrop fades — the iPod itself stays solid as it flies in */
.ipod::before {
  content: ""; position: fixed; inset: 0; z-index: -1;
  background: rgba(13,13,13,.55); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
  opacity: 0; transition: opacity .35s;
}
.ipod.open::before { opacity: 1; }
.ipod__body {
  width: min(300px, 80vw); aspect-ratio: 300 / 500; border-radius: 34px; padding: 22px;
  background: var(--plastic); display: grid; grid-template-rows: 44% 1fr; gap: 22px;
  box-shadow: 0 30px 60px rgba(0,0,0,.35), inset 0 0 0 1px rgba(0,0,0,.07), inset 0 -3px 8px rgba(0,0,0,.05);
  transform-origin: 50% 50%; will-change: transform;
}
.ipod__hint { transition: opacity .3s .25s; opacity: 0; }
.ipod.open .ipod__hint { opacity: 1; }
.ipod-btn.is-away { visibility: hidden; }
.ipod__screen { background: #f4f8ff; border-radius: 8px; border: 3px solid #333; overflow: hidden; font-size: 15px; }
.ipod__bar { display: flex; justify-content: space-between; align-items: center; padding: 4px 8px; font-weight: 700; font-size: 12px; background: linear-gradient(#fff, #cfd8e3); border-bottom: 1px solid #889; }
.ipod__batt { width: 22px; height: 10px; border: 1.5px solid #333; border-radius: 2px; background: linear-gradient(90deg, #5c5 70%, transparent 0); }
.ipod__list { list-style: none; margin: 0; padding: 0; position: relative; max-height: 174px; overflow-y: auto; scrollbar-width: none; overscroll-behavior: contain; }
.ipod__list::-webkit-scrollbar { display: none; }
.ipod__list.more { -webkit-mask: linear-gradient(#000 90%, rgba(0,0,0,.35)); mask: linear-gradient(#000 90%, rgba(0,0,0,.35)); }
.ipod__list li { display: flex; justify-content: space-between; padding: 5px 10px; font-weight: 700; cursor: pointer; }
.ipod__list li.on { background: linear-gradient(#5fa8ff, #1d6fe0); color: #fff; }
.wheel { position: relative; width: 82%; aspect-ratio: 1; margin: auto; border-radius: 50%; background: #f6f5f2; box-shadow: inset 0 0 0 1px rgba(0,0,0,.06), inset 0 1px 3px rgba(0,0,0,.06); touch-action: none; }
.wheel__lbl { position: absolute; border: 0; background: none; color: #999; font-weight: 700; font-size: 12px; padding: 8px; }
.wheel__lbl--top { top: 6%; left: 50%; translate: -50% 0; }
.wheel__lbl--bottom { bottom: 6%; left: 50%; translate: -50% 0; }
.wheel__lbl--left { left: 4%; top: 50%; translate: 0 -50%; }
.wheel__lbl--right { right: 4%; top: 50%; translate: 0 -50%; }
.wheel__center { position: absolute; inset: 33%; border-radius: 50%; border: 0; background: var(--plastic); box-shadow: 0 0 0 1px rgba(0,0,0,.08), 0 1px 2px rgba(0,0,0,.1); }
.wheel__center:active { transform: scale(.95); }
.ipod__hint { color: var(--paper); font-weight: 500; font-size: 13px; margin: 0; }

/* ---------- lightbox ---------- */
.lightbox {
  position: fixed; inset: 0; z-index: 90; background: rgba(13,13,13,.94); display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto; grid-template-rows: minmax(0, 1fr); align-items: center; gap: 10px; padding: 60px 10px 20px;
  opacity: 0; transition: opacity .25s; overflow: hidden; overscroll-behavior: contain; touch-action: none;
}
/* the whole picture always fits the screen */
.lightbox .lb-media img { max-height: calc(100svh - 190px); max-width: 100%; width: auto; height: auto; }
.lightbox.open { opacity: 1; }
.lb-fig { margin: 0; height: 100%; min-height: 0; display: grid; grid-template-rows: 1fr auto; gap: 14px; min-width: 0; }
.lb-media { min-height: 0; display: grid; place-items: center; }
.lb-media img, .lb-media video { max-width: 100%; max-height: 100%; object-fit: contain; transform: scale(.94); transition: transform .4s cubic-bezier(.2,1.4,.4,1); }
.lightbox.open .lb-media img, .lightbox.open .lb-media video { transform: none; }
.lb-media iframe { width: min(100%, 1000px); aspect-ratio: 16 / 9; border: 0; }
.lb-cap { color: var(--paper); text-align: center; display: grid; gap: 4px; }
.lb-cap strong { font-family: var(--display); font-weight: 600; font-size: 20px; }
.lb-close, .lb-nav { border: 0; background: var(--paper); color: var(--ink); width: 48px; height: 48px; border-radius: 50%; font-size: 18px; }
.lb-close { position: absolute; top: 14px; right: 14px; }
@media (max-width: 600px) { .lightbox { grid-template-columns: 1fr; } .lb-nav { position: absolute; bottom: 18px; } .lb-prev { left: 14px; } .lb-next { right: 14px; } }

/* ---------- sketchbook viewer ---------- */
.viewer {
  --book: var(--c1);
  position: fixed; inset: 0; z-index: 70; background-color: var(--book); color: var(--ink);
  background-image: radial-gradient(rgba(0,0,0,.16) 2px, transparent 2.2px); background-size: 18px 18px;
}
.viewer { transition: opacity .38s ease; }
.viewer.is-faded { opacity: 0; }
.viewer__canvas { position: absolute; inset: 0; width: 100%; height: 100%; touch-action: none; cursor: grab; }
.viewer__canvas:active { cursor: grabbing; }
.viewer__top, .viewer__bottom { position: absolute; left: 0; right: 0; display: flex; align-items: center; gap: 12px; padding: 14px var(--gutter); pointer-events: none; }
.viewer__top > *, .viewer__bottom > * { pointer-events: auto; }
.viewer__top { top: 0; justify-content: space-between; }
.viewer__bottom { bottom: 0; justify-content: center; padding-bottom: max(18px, env(safe-area-inset-bottom)); }
.viewer__title { background: var(--ink); color: var(--paper); padding: 10px 16px; border-radius: 16px; display: grid; gap: 2px; min-width: 0; }
.viewer__title strong { font-family: var(--display); font-weight: 600; font-size: 16px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.viewer__title span { font-size: 12px; opacity: .8; }
.viewer__tools { display: flex; gap: 8px; }
.vbtn { width: 44px; height: 44px; border: 3px solid var(--ink); border-radius: 50%; background: var(--paper); color: var(--ink); font-size: 18px; font-weight: 700; display: grid; place-items: center; box-shadow: 3px 3px 0 var(--ink); transition: transform .12s; }
.vbtn:active { transform: translate(2px, 2px); box-shadow: 1px 1px 0 var(--ink); }
.vbtn.off { text-decoration: line-through; opacity: .5; }
.vbtn--big { width: 56px; height: 56px; }
.viewer__count { background: var(--ink); color: var(--paper); font-family: var(--display); font-size: 14px; padding: 12px 18px; border-radius: 999px; min-width: 130px; text-align: center; }
.viewer__count i { font-style: normal; opacity: .6; }
.viewer__hint { position: absolute; bottom: 86px; left: 0; right: 0; text-align: center; font-size: 12px; font-weight: 700; margin: 0; pointer-events: none; animation: fadeHint 5s forwards; }
@keyframes fadeHint { 70% { opacity: 1; } to { opacity: 0; } }

/* ---------- now playing (background music) ---------- */
.np { position: fixed; z-index: 60; right: max(16px, env(safe-area-inset-right, 0px)); bottom: max(16px, env(safe-area-inset-bottom, 0px)); }
.np__player { position: absolute; right: 0; bottom: 0; width: 200px; height: 200px; opacity: 0; pointer-events: none; overflow: hidden; }
.np__pill {
  position: relative; display: flex; align-items: center; gap: 10px; max-width: min(300px, calc(100vw - 32px));
  padding: 6px 12px 6px 6px; border: 3px solid var(--ink); border-radius: 999px; background: var(--chrome); color: var(--ink);
  box-shadow: 4px 4px 0 var(--ink); transition: translate .15s, box-shadow .15s;
}
.np__pill:hover { translate: -2px -2px; box-shadow: 6px 6px 0 var(--ink); }
.np__pill:active { translate: 2px 2px; box-shadow: 1px 1px 0 var(--ink); }
.np__art { width: 38px; height: 38px; border-radius: 50%; object-fit: cover; border: 2px solid var(--ink); flex: none; }
.np__art--disc { display: block; background: radial-gradient(circle, var(--paper) 18%, var(--ink) 20%, var(--ink) 34%, var(--c1) 36%, var(--c1) 60%, var(--ink) 62%); }
.is-playing .np__art { animation: spin 6s linear infinite; }
@keyframes spin { to { rotate: 360deg; } }
.np__txt { display: grid; min-width: 0; text-align: left; line-height: 1.15; }
.np__txt b { font-family: var(--display); font-weight: 600; font-size: 10px; letter-spacing: .05em; }
.np__title { font-size: 12px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 170px; }
.np__btn { flex: none; width: 28px; height: 28px; border-radius: 50%; background: var(--ink); color: var(--paper); display: grid; place-items: center; font-size: 10px; }
.np__eq { display: none; gap: 2px; align-items: end; height: 16px; flex: none; }
.is-playing .np__eq { display: flex; }
.np__eq i { width: 3px; background: var(--ink); border-radius: 2px; animation: eq .9s ease-in-out infinite; }
.np__eq i:nth-child(2) { animation-delay: -.3s; } .np__eq i:nth-child(3) { animation-delay: -.6s; } .np__eq i:nth-child(4) { animation-delay: -.15s; }
@keyframes eq { 0%, 100% { height: 4px; } 50% { height: 16px; } }
@media (max-width: 520px) { .np__txt { display: none; } .np__pill { padding-right: 6px; } }

/* ---------- glitch layer + CRT texture ---------- */
html.is-scrolling .glitch-layer, html.is-scrolling body::after { visibility: hidden; }
.glitch-layer { position: fixed; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 45; image-rendering: pixelated; }
body::after {
  content: ""; position: fixed; inset: 0; pointer-events: none; z-index: 44;
  background: repeating-linear-gradient(to bottom, rgba(0,0,0,.05) 0 1px, transparent 1px 3px);
}
.sec-title, .hero__name, .contact__big { position: relative; }
.glitching { animation: gl-shake .12s steps(2) infinite; }
.glitching::before, .glitching::after {
  content: attr(data-text); position: absolute; inset: 0; pointer-events: none;
}
.glitching::before { color: var(--c1); transform: translate(-3px, 1px); clip-path: inset(10% 0 55% 0); animation: gl-slice .18s steps(3) infinite; }
.glitching::after { color: var(--c2); transform: translate(3px, -1px); clip-path: inset(60% 0 8% 0); animation: gl-slice .22s steps(3) infinite reverse; }
@keyframes gl-slice { 0% { clip-path: inset(10% 0 60% 0); } 33% { clip-path: inset(45% 0 30% 0); } 66% { clip-path: inset(75% 0 5% 0); } 100% { clip-path: inset(20% 0 50% 0); } }
@keyframes gl-shake { 0% { translate: 0 0; } 50% { translate: 2px -1px; } 100% { translate: -2px 1px; } }
@media (prefers-reduced-motion: reduce) { .glitching, .glitching::before, .glitching::after { animation: none; } body::after { display: none; } }

/* ---------- full-screen splash ---------- */
.splash-overlay { position: fixed; inset: 0; width: 100vw; height: 100vh; z-index: 100; pointer-events: none; display: none; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
  html { scroll-behavior: auto; }
}

/* ---------- NSFW age gate ---------- */
.agegate { position: fixed; inset: 0; z-index: 90; display: grid; place-items: center; padding: 16px;
  background: rgba(13,13,13,.72); backdrop-filter: blur(6px); opacity: 0; transition: opacity .25s; }
.agegate.is-in { opacity: 1; }
.agegate__card { width: min(360px, 100%); background: var(--paper); color: var(--ink); border: 3px solid var(--ink);
  border-radius: 20px; box-shadow: 6px 6px 0 var(--book, var(--c1)); padding: 22px 20px 18px; display: grid; gap: 10px;
  transform: translateY(14px) scale(.97); transition: transform .25s; }
.agegate.is-in .agegate__card { transform: none; }
.agegate__tag { margin: 0; justify-self: start; background: var(--ink); color: var(--c0); font-family: var(--display);
  font-size: 12px; padding: 5px 10px; border-radius: 999px; }
.agegate__title { margin: 0; font-family: var(--display); font-weight: 600; font-size: 18px; line-height: 1.25; }
.agegate__q { font-weight: 700; font-size: 14px; }
.agegate__in { font-family: var(--display); font-size: 28px; letter-spacing: .12em; text-align: center; width: 100%;
  padding: 10px; border: 3px solid var(--ink); border-radius: 14px; background: #fff; color: var(--ink); }
.agegate__in:focus { outline: none; box-shadow: 0 0 0 4px var(--book, var(--c1)); }
.agegate__msg { margin: 0; min-height: 1.2em; font-size: 13px; font-weight: 700; color: #c0124f; }
.agegate__btns { display: flex; gap: 10px; justify-content: space-between; }
.agegate__btns button { flex: 1; padding: 12px; border-radius: 999px; border: 3px solid var(--ink); font-family: var(--body);
  font-weight: 700; font-size: 14px; cursor: pointer; }
.agegate__no { background: var(--paper); color: var(--ink); }
.agegate__yes { background: var(--ink); color: var(--paper); box-shadow: 3px 3px 0 var(--book, var(--c1)); }
.lb-note { display: block; font-style: normal; font-size: 13px; opacity: .8; margin-top: 4px; }

.wsec__years { display: flex; flex-wrap: wrap; gap: 6px; padding: 14px var(--gutter) 0; position: relative; z-index: 3; }
.wyear { border: 2px solid var(--sec-ink, var(--ink)); background: transparent; color: var(--sec-ink, var(--ink)); border-radius: 999px;
  padding: 5px 12px; font: 700 13px var(--body); cursor: pointer; transition: transform .12s; }
.wyear small { opacity: .6; font-size: 11px; margin-left: 2px; }
.wyear:hover { transform: translateY(-2px); }
.wyear.on { background: var(--sec-ink, var(--ink)); color: var(--wbg); }
.wsec__flow { transition: opacity .18s; min-height: clamp(340px, 52vh, 540px); }
.wsec__flow.out { opacity: 0; }

/* ---------- text frames (commonSans badKern look, free stand-in: Sofia Sans Extra Condensed, OFL) ---------- */
@font-face { font-family: "FrameSans"; src: url("../assets/fonts/sofia-sans-extra-condensed-latin-300-normal.woff2") format("woff2"); font-weight: 300; font-display: swap; }
@font-face { font-family: "FrameSans"; src: url("../assets/fonts/sofia-sans-extra-condensed-latin-500-normal.woff2") format("woff2"); font-weight: 500; font-display: swap; }
:root { --frame: "FrameSans", "Arial Narrow", sans-serif; }
.framed { font-family: var(--frame) !important; font-weight: 300; text-transform: none !important; letter-spacing: 0; }
.framed .frame {
  display: table; background: var(--fbg); color: var(--ffg); margin-left: var(--find);
  padding: 0 .06em; line-height: .84; letter-spacing: -.08em;   /* bad kerning: letters bump into each other */
  font-kerning: none; font-feature-settings: "kern" 0;
}
.framed .frame::after { content: ""; display: inline-block; width: .07em; }   /* give back the last letter's squeeze */
/* pressed by hand: each block a touch crooked, letters a hair off-register from their block,
   ink a little heavier at the edges, rough + speckled through the #ink filter */
/* clean, flat, digital blocks; the only "ink" is where letters meet (#jellyL/M/S) */
.framed .frame { background: var(--fbg); position: relative; }
.framed .frame__ink { display: inline-block; filter: url(#jellyM); }
.framed[data-jelly="L"] .frame__ink { filter: url(#jellyL); }
.framed[data-jelly="S"] .frame__ink { filter: url(#jellyS); }
.framed.glitching::before, .framed.glitching::after { display: none; }
.hero__name.framed { font-size: clamp(80px, min(26vw, 21svh), 270px); }
.sec-title.framed { font-size: clamp(60px, 13vw, 170px); }
.wsec__title.framed { font-size: clamp(52px, 10vw, 120px); }
.contact__big.framed { font-size: clamp(110px, 26vw, 360px); }
.hero__words span.framed-word { font-family: var(--frame); font-weight: 500; letter-spacing: -.05em; font-size: 1.35em; line-height: .9; padding: 0 .12em .02em; }
.hero__words { height: 1.25em; }
/* top bar: just the iPod (it opens the menu) — the name and link pills repeated the page */
.topbar .logo, .topbar .toplinks { display: none; }
.topbar { justify-content: flex-end; }
/* the serif reads a bit small next to the old fonts: semibold by default, a touch larger */
body { font-weight: 500; font-size: 17px; }
.marquee__track, .feed-card__kicker, .contact__slogan, .contact__email, .viewer__count, .agegate__tag, .agegate__in, .x-media--glyph span { font-weight: 600; }
.marquee { display: none; }   /* scrolling text bar under the hero: removed */
/* Work intro is its own dark band, so the Drawings carousel reads as a separate section below it */
.work { background: var(--ink); color: var(--paper); }
.work > .sec-head { padding-bottom: 44px; }
.work-nav .series-tab { background: transparent; border-color: var(--paper); color: var(--paper); }
.work-nav .series-tab:hover { background: var(--paper); color: var(--ink); }
.work-nav .series-tab i { border-color: var(--paper); }
.work__list { margin-top: 0; }
.wsec:first-child { border-top: 3px solid var(--ink); }
/* smaller titles (phones, Work section headings) get a finer ink filter so they stay crisp */
/* the iPod keeps a plain system sans, like a real iPod screen */
.ipod, .ipod-btn, .np { font-family: -apple-system, BlinkMacSystemFont, "Helvetica Neue", Helvetica, Arial, sans-serif; }
.np__txt b { font-family: inherit; }
.hero__words { height: auto; overflow: visible; margin-top: 26px; }
