/* Layout concept: a builder's index. One loud move (a live, lit normal-map
   surface behind the name), then quiet, catalogue-style lists.
   Light: ink on warm-neutral paper with a deep-olive accent and lime fills.
   Dark: graphite with an electric lime accent. */
:root {
  --paper: #F3F4EE;
  --paper-2: #E7E9DF;
  --card: #FBFBF7;
  --ink: #12140D;
  --muted: #5C6152;
  --line: #D6D9CB;
  --accent: #3E6B00;     /* readable lime-olive for text and lines */
  --accent-ink: #FFFFFF;
  --pop: #C6F432;        /* lime fill */
  --pop-ink: #12140D;
  --live: #0E9F6E;
  --hero-deep: #B9BFAC; --hero-base: #F7F8F2; --hero-pop: #5E9E00; --hero-dark: 0;
  --f-display: "Bricolage Grotesque", "Arial Narrow", system-ui, sans-serif;
  --f-body: "Hanken Grotesk", system-ui, -apple-system, "Segoe UI", sans-serif;
  --f-mono: "JetBrains Mono", ui-monospace, "Cascadia Code", Consolas, monospace;
  --maxw: 1200px;
  --r: 14px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #0B0C09; --paper-2: #181A13; --card: #121410; --ink: #EEF1E6; --muted: #9AA08C;
    --line: #272A20; --accent: #C6F432; --accent-ink: #0B0C09; --pop: #C6F432; --pop-ink: #0B0C09; --live: #C6F432;
    --hero-deep: #050604; --hero-base: #2E3324; --hero-pop: #C6F432; --hero-dark: 1;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --paper: #0B0C09; --paper-2: #181A13; --card: #121410; --ink: #EEF1E6; --muted: #9AA08C;
  --line: #272A20; --accent: #C6F432; --accent-ink: #0B0C09; --pop: #C6F432; --pop-ink: #0B0C09; --live: #C6F432;
  --hero-deep: #050604; --hero-base: #2E3324; --hero-pop: #C6F432; --hero-dark: 1;
  color-scheme: dark;
}
::selection { background: var(--pop); color: var(--pop-ink); }

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font: 400 17px/1.6 var(--f-body); -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
p a, .soon a { color: var(--accent); text-underline-offset: 3px; }
h1, h2, h3 { font-family: var(--f-display); font-weight: 700; line-height: 1.05; letter-spacing: -0.02em; margin: 0; text-wrap: balance; }
.mono { font-family: var(--f-mono); font-size: 0.78rem; letter-spacing: 0.01em; }
.eyebrow {
  font-family: var(--f-mono); font-size: 0.74rem; text-transform: uppercase; letter-spacing: 0.08em;
  color: var(--muted); margin: 0;
}
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: var(--paper); padding: 8px 12px; z-index: 50; }
.skip:focus { left: 16px; }
.i { width: 1em; height: 1em; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: none; }

.wrap {
  max-width: var(--maxw); margin: 0 auto;
  padding-left: max(20px, env(safe-area-inset-left, 0px));
  padding-right: max(20px, env(safe-area-inset-right, 0px));
}

/* ── header ─────────────────────────────── */
.top {
  position: sticky; top: 0; z-index: 20;
  background: color-mix(in srgb, var(--paper) 82%, transparent);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent; transition: border-color .2s;
}
.top.scrolled { border-bottom-color: var(--line); }
.top-in { display: flex; align-items: center; gap: 24px; height: 64px; }
.mark { display: inline-flex; align-items: flex-end; gap: 3px; text-decoration: none; }
.mark-p { font: 800 1.7rem/1 var(--f-display); letter-spacing: -0.04em; }
.mark-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--pop); box-shadow: 0 0 0 1px var(--accent); margin-bottom: 5px; }
.nav { display: flex; gap: 4px; margin-left: auto; }
.nav a {
  text-decoration: none; font-weight: 500; font-size: 0.95rem; color: var(--muted);
  padding: 6px 12px; border-radius: 999px; transition: color .15s, background .15s;
}
.nav a:hover { color: var(--ink); background: var(--paper-2); }
.nav a[aria-current="page"] { color: var(--ink); background: var(--paper-2); }
.top-tools { display: flex; gap: 6px; }
.tbtn {
  width: 38px; height: 38px; border-radius: 50%; border: 1px solid var(--line); background: transparent;
  color: var(--ink); cursor: pointer; display: grid; place-items: center;
}
.tbtn:hover { background: var(--paper-2); }
.sun { width: 14px; height: 14px; border-radius: 50%; border: 2px solid currentColor; background: linear-gradient(90deg, currentColor 50%, transparent 50%); }
.menu { display: none; }
.menu span { display: block; width: 16px; height: 2px; background: currentColor; border-radius: 2px; transition: transform .2s; }
.menu { gap: 4px; align-content: center; }
.menu[aria-expanded="true"] span:first-child { transform: translateY(3px) rotate(45deg); }
.menu[aria-expanded="true"] span:last-child { transform: translateY(-3px) rotate(-45deg); }

/* ── hero ──────────────────────────────── */
.pulse {
  width: 8px; height: 8px; border-radius: 50%; background: var(--live); display: inline-block; flex: none;
  box-shadow: 0 0 0 0 color-mix(in srgb, var(--live) 60%, transparent); animation: pulse 2.2s infinite;
}
@keyframes pulse { 70% { box-shadow: 0 0 0 7px transparent; } 100% { box-shadow: 0 0 0 0 transparent; } }
.hero {
  position: relative; isolation: isolate; overflow: hidden;
  background: radial-gradient(120% 90% at 75% 30%, var(--hero-base), var(--hero-deep));
  border-bottom: 1px solid var(--line);
}
.hero-canvas { position: absolute; inset: 0; width: 100%; height: 100%; z-index: -2; opacity: 0; transition: opacity 1.2s ease; display: block; }
.hero-canvas.ready { opacity: 1; }
.hero-scrim {
  position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background:
    linear-gradient(90deg, color-mix(in srgb, var(--paper) 80%, transparent) 0%, color-mix(in srgb, var(--paper) 30%, transparent) 55%, transparent 80%),
    linear-gradient(0deg, color-mix(in srgb, var(--paper) 70%, transparent) 0%, transparent 30%);
}
.hero-in {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 32px 56px; align-items: center;
  padding-block: clamp(48px, 9vw, 120px) clamp(28px, 4vw, 48px);
}
.hero-copy { min-width: 0; }
.hero-eye {
  display: inline-flex; align-items: center; gap: 10px; margin: 0; padding: 7px 12px; border-radius: 999px;
  background: color-mix(in srgb, var(--card) 70%, transparent); border: 1px solid var(--line);
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
}
.hero-name {
  font-size: clamp(3rem, 10.5vw, 9.6rem); font-weight: 800; letter-spacing: -0.055em; line-height: 0.86;
  margin: 22px 0 10px -0.04em; font-variation-settings: "opsz" 96; display: flex; flex-wrap: nowrap;
  overflow: hidden; padding-bottom: 0.08em;
}
.hero-name span { display: inline-block; animation: rise .9s cubic-bezier(.2,.8,.2,1) both; animation-delay: calc(var(--i) * 45ms); }
@keyframes rise { from { transform: translateY(105%); } to { transform: none; } }
.hero-is { font: 600 clamp(1.3rem, 2.8vw, 2.1rem)/1.25 var(--f-display); letter-spacing: -0.02em; margin: 0 0 22px; color: var(--muted); }
.hero-role-word {
  display: inline-block; color: var(--pop-ink); background: var(--pop); padding: 0 0.28em 0.04em; border-radius: 0.18em;
  transition: transform .32s cubic-bezier(.2,.8,.2,1), opacity .32s; transform-origin: left center;
}
.hero-role-word.out { opacity: 0; transform: translateY(0.35em) rotate(-2deg); }
.hero-lede { font-size: clamp(1.05rem, 1.7vw, 1.25rem); line-height: 1.5; max-width: 44ch; margin: 0; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 28px; }
.btn.btn-pop { background: var(--pop); color: var(--pop-ink); border-color: var(--pop); }
.btn.btn-pop:hover { border-color: var(--ink); }
.btn.btn-ghost { background: color-mix(in srgb, var(--card) 60%, transparent); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }

.hero-portrait { margin: 0; display: grid; gap: 14px; justify-items: center; }
.portrait-frame {
  position: relative; width: clamp(190px, 22vw, 290px); aspect-ratio: 413 / 531; max-width: 100%;
  border-radius: 200px 200px 18px 18px; overflow: hidden; background: var(--pop);
  box-shadow: 0 0 0 6px color-mix(in srgb, var(--paper) 70%, transparent), 14px 14px 0 6px var(--pop);
  transform: rotate(2deg); transition: transform .4s cubic-bezier(.2,.8,.2,1);
}
.hero-portrait:hover .portrait-frame { transform: rotate(0deg) translateY(-4px); }
.portrait-frame img { width: 100%; height: 100%; object-fit: cover; object-position: center 20%; position: relative; z-index: 1; }
.portrait-mono { position: absolute; inset: 0; display: grid; place-items: center; font: 800 8rem/1 var(--f-display); color: var(--pop-ink); }
.no-photo img { display: none; }
.hero-portrait figcaption { color: var(--muted); padding: 5px 10px; border-radius: 999px; background: color-mix(in srgb, var(--card) 70%, transparent); }

.hero-foot { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 12px 24px; padding-block: 0 22px; }
.hero-fig { margin: 0; color: var(--muted); max-width: 72ch; }
.hero-fig span { color: var(--ink); }
.hero-tools { display: flex; gap: 8px; }
.chip-btn {
  font: 500 0.74rem/1 var(--f-mono); padding: 8px 12px; border-radius: 999px; cursor: pointer;
  border: 1px solid var(--line); background: color-mix(in srgb, var(--card) 70%, transparent); color: var(--ink);
}
.chip-btn:hover { border-color: var(--ink); }
.chip-btn[aria-pressed="true"] { background: var(--pop); color: var(--pop-ink); border-color: var(--pop); }

/* activity strip */
.strip { margin: 0; padding-top: 20px; border-top: 1px solid var(--line); }
.strip-grid { display: grid; grid-template-columns: repeat(var(--n), minmax(0, 1fr)); align-items: end; gap: 2px; }
.col { display: flex; flex-direction: column; align-items: center; gap: 8px; min-width: 0; }
.dots { display: flex; flex-direction: column-reverse; gap: 5px; min-height: 12px; }
.dot {
  width: 12px; height: 12px; border-radius: 3px; background: var(--accent); position: relative; display: block;
  transition: transform .15s;
}
.dot:hover, .dot:focus-visible { transform: scale(1.35); }
.dot::after {
  content: attr(data-tip); position: absolute; bottom: calc(100% + 8px); left: 50%; transform: translateX(-50%);
  background: var(--ink); color: var(--paper); font: 500 11px/1 var(--f-mono); padding: 6px 8px; border-radius: 6px;
  white-space: nowrap; pointer-events: none; opacity: 0; transition: opacity .12s; z-index: 5;
}
.dot:hover::after, .dot:focus-visible::after { opacity: 1; }
.col:first-child .dot::after { left: 0; transform: none; }
.col:last-child .dot::after { left: auto; right: 0; transform: none; }
.col.empty .dots::before { content: ""; width: 12px; height: 2px; background: var(--line); border-radius: 2px; }
.mlab { color: var(--muted); font-size: 0.68rem; white-space: nowrap; }
.strip figcaption { margin-top: 14px; color: var(--muted); }
.strip figcaption b { color: var(--ink); }
.hint { opacity: .7; margin-left: 6px; }
.hint::before { content: "· "; }

/* ── sections ──────────────────────────── */
.sec { padding-block: clamp(48px, 7vw, 88px) 0; }
.sec-tight { padding-block: 32px 0; }
.sec-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; margin-bottom: 24px; flex-wrap: wrap; }
.sec-head h2 { font-size: clamp(1.8rem, 4vw, 2.6rem); }
.more { display: inline-flex; align-items: center; gap: 6px; text-decoration: none; font-weight: 600; color: var(--accent); }
.more:hover .i { transform: translate(2px, -2px); }
.i { transition: transform .15s; }

/* featured grid */
.fgrid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 16px; }
.fcard {
  position: relative; background: var(--card); border: 1px solid var(--line); border-radius: var(--r);
  padding: clamp(20px, 3vw, 32px); display: flex; gap: 32px; overflow: hidden; min-width: 0;
  transition: border-color .2s, transform .2s;
}
.fcard:hover { border-color: var(--accent); transform: translateY(-2px); }
.fcard-link { position: absolute; inset: 0; z-index: 1; }
.fcard-link:focus-visible { outline-offset: -3px; border-radius: var(--r); }
.f-hero { grid-column: span 6; align-items: center; }
.f-half { grid-column: span 3; }
.f-third { grid-column: span 2; }
.fcard-text { display: flex; flex-direction: column; gap: 12px; min-width: 0; flex: 1; }
.fcard h3 { font-size: clamp(1.5rem, 2.6vw, 2rem); }
.f-hero h3 { font-size: clamp(2.2rem, 5vw, 3.6rem); }
.fcard-tag { margin: 0; color: var(--muted); max-width: 46ch; }
.f-hero .fcard-tag { font-size: 1.15rem; color: var(--ink); }
.fcard-shot {
  flex: 1.15; min-width: 0; border-radius: 10px; overflow: hidden; border: 1px solid var(--line);
  aspect-ratio: 16 / 10; background: var(--paper-2); max-width: 100%;
}
.fcard-shot img { width: 100%; height: 100%; object-fit: cover; object-position: top left; }
.chips { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; padding: 0; margin: 4px 0 0; }
.chip {
  font: 500 0.72rem/1 var(--f-mono); padding: 6px 9px; border-radius: 6px; background: var(--paper-2);
  color: var(--muted); white-space: nowrap;
}
.live-chip {
  position: relative; z-index: 2; align-self: flex-start; margin-top: auto;
  display: inline-flex; align-items: center; gap: 8px; font: 500 0.8rem/1 var(--f-mono);
  color: var(--live); text-decoration: none; padding: 8px 12px 8px 10px; border: 1px solid color-mix(in srgb, var(--live) 40%, transparent);
  border-radius: 999px;
}
.live-chip:hover { background: color-mix(in srgb, var(--live) 12%, transparent); }
.stats { display: flex; gap: 28px; margin: 4px 0; flex-wrap: wrap; }
.stats div { display: flex; flex-direction: column-reverse; }
.stats dt { font: 0.72rem var(--f-mono); color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }
.stats dd { margin: 0; font: 700 1.8rem/1.1 var(--f-display); color: var(--accent); font-variant-numeric: tabular-nums; }

/* hubs */
.hubs { list-style: none; padding: 0; margin: 0; border-top: 1px solid var(--line); }
.hub {
  display: grid; grid-template-columns: 56px minmax(0, 1fr) minmax(0, 1fr) 40px; align-items: center; gap: 16px;
  padding: clamp(18px, 3vw, 30px) 8px; border-bottom: 1px solid var(--line); text-decoration: none;
  position: relative; isolation: isolate;
}
.hub::before {
  content: ""; position: absolute; inset: 0; background: var(--pop); z-index: -1;
  transform: scaleY(0); transform-origin: bottom; transition: transform .35s cubic-bezier(.2,.8,.2,1);
}
.hub:hover::before, .hub:focus-visible::before { transform: scaleY(1); }
.hub:hover, .hub:focus-visible { color: var(--pop-ink); }
.hub:hover .hub-d, .hub:hover .hub-n, .hub:focus-visible .hub-d, .hub:focus-visible .hub-n { color: var(--pop-ink); }
.hub-n { color: var(--muted); }
.hub-l { font: 700 clamp(2rem, 6vw, 4.4rem)/1 var(--f-display); letter-spacing: -0.035em; }
.hub-d { color: var(--muted); }
.hub-a { font-size: 1.8rem; justify-self: end; display: flex; }
.hub:hover .hub-a .i { transform: translate(3px, -3px); }

/* ── page heads & index ────────────────── */
.phead { padding-block: clamp(40px, 7vw, 88px) 8px; }
.phead h1 { font-size: clamp(2.8rem, 9vw, 6.5rem); font-weight: 800; letter-spacing: -0.045em; margin: 10px 0 18px; }
.phead-lede { font-size: clamp(1.1rem, 2vw, 1.35rem); line-height: 1.45; max-width: 52ch; margin: 0; color: var(--ink); }
.index { list-style: none; padding: 0; margin: 0; border-top: 1px solid var(--line); }
.irow {
  display: grid; grid-template-columns: 150px minmax(0, 1fr) minmax(0, 220px) 28px; gap: 20px; align-items: baseline;
  padding: 22px 8px; border-bottom: 1px solid var(--line); text-decoration: none; transition: background .15s;
}
.irow:hover { background: var(--card); }
.irow:hover .irow-t { color: var(--accent); }
.irow:hover .irow-a .i { transform: translate(2px, -2px); }
.irow-meta { color: var(--muted); }
.irow-main { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.irow-t { font: 700 1.45rem/1.15 var(--f-display); letter-spacing: -0.02em; transition: color .15s; }
.irow-d { color: var(--muted); }
.irow-side { color: var(--muted); font-size: 0.9rem; text-align: right; }
.irow-a { color: var(--muted); display: flex; justify-content: flex-end; }
.live-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--live); vertical-align: middle; margin-left: 4px; }

/* ── detail ────────────────────────────── */
.crumbs { display: flex; gap: 8px; flex-wrap: wrap; color: var(--muted); }
.crumbs a { text-decoration: none; }
.crumbs a:hover { color: var(--accent); }
.dhead h1 { margin-bottom: 6px; }
.dsub { font: 500 clamp(1.1rem, 2vw, 1.4rem)/1.3 var(--f-display); color: var(--accent); margin: 0 0 18px; }
.btns { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 26px; }
.btn {
  display: inline-flex; align-items: center; gap: 8px; text-decoration: none; font-weight: 600; font-size: 0.95rem;
  padding: 11px 16px; border-radius: 999px; border: 1px solid var(--line); background: var(--card);
}
.btn:hover { border-color: var(--ink); }
.btn:hover .i:last-child { transform: translate(2px, -2px); }
.btn-live { background: var(--ink); color: var(--paper); border-color: var(--ink); font-family: var(--f-mono); font-weight: 500; font-size: 0.85rem; }
.btn-live:hover { background: var(--pop); border-color: var(--pop); color: var(--pop-ink); }
.dgrid { display: grid; grid-template-columns: 280px minmax(0, 1fr); gap: clamp(28px, 5vw, 72px); align-items: start; }
.dmeta { position: sticky; top: 88px; display: flex; flex-direction: column; gap: 16px; padding-top: 24px; border-top: 2px solid var(--ink); }
.dmeta > dl { margin: 0; display: grid; gap: 12px; }
.dmeta > dl > div { display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: 8px; }
.dmeta dt { font: 0.72rem/1.8 var(--f-mono); text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.dmeta dd { margin: 0; font-weight: 500; }
.dmeta .stats dd { font-size: 1.6rem; }
.dbody { min-width: 0; max-width: 68ch; padding-top: 18px; }
.dsum { font-size: 1.2rem; line-height: 1.6; margin: 0 0 8px; }
.dbody h2 { font-size: 1.5rem; margin: 40px 0 14px; }
.dbody p { margin: 0 0 14px; }
.hl { list-style: none; padding: 0; margin: 0; display: grid; gap: 0; counter-reset: hl; }
.hl li { position: relative; padding: 14px 0 14px 44px; border-top: 1px solid var(--line); counter-increment: hl; }
.hl li::before {
  content: counter(hl, decimal-leading-zero); position: absolute; left: 0; top: 16px;
  font: 500 0.75rem var(--f-mono); color: var(--accent);
}
.gallery { display: grid; gap: 20px; margin-top: 40px; grid-template-columns: 1fr 1fr; }
.gallery figure { margin: 0; min-width: 0; }
.gallery figure:first-child, .gallery figure:only-child { grid-column: 1 / -1; }
.gallery a { display: block; border-radius: 10px; overflow: hidden; border: 1px solid var(--line); background: var(--paper-2); transition: border-color .2s; }
.gallery a:hover { border-color: var(--accent); }
.gallery img { display: block; width: 100%; height: auto; max-height: 520px; object-fit: cover; object-position: top center; }
.gallery figure:first-child img { max-height: 720px; }
@media (max-width: 720px) { .gallery { grid-template-columns: 1fr; } }
.gallery figcaption { color: var(--muted); margin-top: 8px; }
.pn { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: clamp(56px, 8vw, 96px); }
.pn a {
  display: flex; flex-direction: column; gap: 6px; padding: 22px; border: 1px solid var(--line); border-radius: var(--r);
  text-decoration: none; transition: border-color .15s; min-width: 0;
}
.pn a:hover { border-color: var(--accent); }
.pn span { color: var(--muted); }
.pn b { font: 700 1.3rem/1.2 var(--f-display); }
.pn-next { text-align: right; }

/* about / 404 */
.soon { border: 1px dashed var(--line); border-radius: var(--r); padding: clamp(20px, 4vw, 36px); max-width: 62ch; display: grid; gap: 10px; }
.soon p { margin: 0; }
.nf { padding-bottom: 80px; }

/* ── footer ────────────────────────────── */
.foot { margin-top: clamp(72px, 10vw, 140px); border-top: 1px solid var(--line); padding-block: 48px 40px; }
.foot-in { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 28px 40px; align-items: end; }
.foot-mail { font: 700 clamp(1.4rem, 4vw, 2.6rem)/1.1 var(--f-display); letter-spacing: -0.03em; margin: 10px 0 0; display: flex; flex-wrap: wrap; align-items: center; gap: 14px; overflow-wrap: anywhere; }
.sel { user-select: all; }
.copy {
  font: 500 0.78rem/1 var(--f-mono); padding: 8px 12px; border-radius: 999px; border: 1px solid var(--line);
  background: transparent; color: var(--ink); cursor: pointer; letter-spacing: 0;
}
.copy:hover { border-color: var(--accent); color: var(--accent); }
.foot-links { list-style: none; padding: 0; margin: 0; display: flex; gap: 22px; }
.foot-links a { text-decoration: none; font-weight: 600; }
.foot-links a:hover { color: var(--accent); }
.foot-meta { grid-column: 1 / -1; color: var(--muted); margin: 0; }

/* ── responsive ────────────────────────── */
@media (max-width: 900px) {
  .f-half, .f-third { grid-column: span 3; }
  .f-third:last-child:nth-child(even) { grid-column: span 6; }
  .f-hero { flex-direction: column; align-items: stretch; }
  .fcard-shot { flex: none; }
  .dgrid { grid-template-columns: minmax(0, 1fr); }
  .dmeta { position: static; }
  .irow { grid-template-columns: 110px minmax(0, 1fr) 24px; }
  .irow-side { display: none; }
  .hub { grid-template-columns: 40px minmax(0, 1fr) 32px; }
  .hub-d { display: none; }
}
@media (max-width: 900px) {
  .hero-in { grid-template-columns: minmax(0, 1fr); }
  .hero-portrait { justify-items: start; grid-row: 1; }
  .portrait-frame { width: 150px; box-shadow: 0 0 0 4px color-mix(in srgb, var(--paper) 70%, transparent), 8px 8px 0 4px var(--pop); }
  .portrait-mono { font-size: 5rem; }
  .hero-scrim { background: linear-gradient(0deg, color-mix(in srgb, var(--paper) 80%, transparent), color-mix(in srgb, var(--paper) 50%, transparent)); }
}
@media (max-width: 720px) {
  .menu { display: grid; }
  .nav {
    position: absolute; top: 64px; left: 0; right: 0; flex-direction: column; gap: 0;
    background: var(--paper); border-bottom: 1px solid var(--line);
    padding: 8px max(20px, env(safe-area-inset-right, 0px)) 16px max(20px, env(safe-area-inset-left, 0px));
    display: none;
  }
  .nav.open { display: flex; }
  .nav a { padding: 14px 4px; border-radius: 0; font-size: 1.15rem; border-bottom: 1px solid var(--line); background: none !important; }
  .top-tools { margin-left: auto; }
  .fgrid { grid-template-columns: minmax(0, 1fr); }
  .f-hero, .f-half, .f-third, .f-third:last-child:nth-child(even) { grid-column: auto; }
  .mlab { font-size: 0.6rem; }
  .dot { width: 9px; height: 9px; border-radius: 2px; }
  .col.empty .dots::before { width: 9px; }
  .hint { display: none; }
  .irow { grid-template-columns: minmax(0, 1fr) 24px; gap: 4px 12px; }
  .irow-meta { grid-column: 1 / -1; }
  .foot-in { grid-template-columns: minmax(0, 1fr); }
  .pn { grid-template-columns: minmax(0, 1fr); }
  .pn-next { text-align: left; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

/* ── testimonial ───────────────────────── */
.quote { margin: 0; display: grid; gap: 22px; }
.quote blockquote { margin: 0; position: relative; padding-top: 0.5em; }
.quote blockquote::before {
  content: "“"; position: absolute; top: -0.32em; left: -0.04em; font: 800 6rem/1 var(--f-display); color: var(--accent);
}
.quote blockquote p {
  margin: 0; font: 600 clamp(1.6rem, 4.2vw, 3rem)/1.12 var(--f-display); letter-spacing: -0.03em; max-width: 26ch;
  text-indent: 0; padding-top: 0.6em; text-wrap: balance;
}
.quote figcaption { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 14px; }
.qby { font-weight: 600; }
.quote figcaption .mono { color: var(--muted); }
.quote figcaption .more { margin-left: auto; }
.quote-full { border: 1px solid var(--line); border-radius: var(--r); background: var(--card); padding: clamp(20px, 3vw, 32px); }
.quote-full blockquote p { font-size: clamp(1.3rem, 2.4vw, 1.7rem); max-width: none; }
.quote-full blockquote::before { font-size: 4.5rem; }
.qmore { margin: 0; display: grid; gap: 14px; border-top: 1px solid var(--line); padding-top: 18px; }
.qmore dt { font: 0.72rem/1.6 var(--f-mono); text-transform: uppercase; letter-spacing: .06em; color: var(--accent); }
.qmore dd { margin: 0; color: var(--muted); }

/* ── publications ──────────────────────── */
.pubs { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.pub {
  display: flex; flex-direction: column; gap: 14px; height: 100%; padding: clamp(20px, 2.6vw, 28px);
  border-top: 3px solid var(--accent); background: var(--card); border-radius: 0 0 var(--r) var(--r);
  text-decoration: none; transition: background .15s;
}
.pub:hover { background: var(--paper-2); }
.pub:hover .pub-t { color: var(--accent); }
.pub-venue { font: 700 1.35rem/1.1 var(--f-display); letter-spacing: -0.02em; font-style: italic; }
.pub-t { line-height: 1.4; transition: color .15s; }
.pub-m { color: var(--muted); margin-top: auto; }
.authors p { margin: 6px 0 0; line-height: 1.5; }
.authors b { color: var(--accent); font-weight: 600; }
.doi { margin: 0; color: var(--muted); overflow-wrap: anywhere; }
.doi a { color: var(--accent); }
@media (max-width: 900px) { .pubs { grid-template-columns: minmax(0, 1fr); } }

/* ── carousel ──────────────────────────── */
.car-ctrl { display: flex; gap: 8px; }
.car-btn {
  width: 42px; height: 42px; border-radius: 50%; border: 1px solid var(--line); background: var(--card); color: var(--ink);
  font: 600 1rem/1 var(--f-body); cursor: pointer; display: grid; place-items: center;
}
.car-btn:hover { background: var(--pop); color: var(--pop-ink); border-color: var(--pop); }
#car-play { font-size: 0.7rem; letter-spacing: -1px; }
.car {
  overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; overscroll-behavior-x: contain;
  scroll-padding-inline: max(20px, calc((100vw - var(--maxw)) / 2 + 20px));
}
.car::-webkit-scrollbar { display: none; }
.car:focus-visible { outline-offset: -2px; }
.car-track {
  list-style: none; margin: 0; display: flex; gap: 18px; width: max-content;
  padding-block: 6px 10px;
  padding-left: max(20px, env(safe-area-inset-left, 0px), calc((100vw - var(--maxw)) / 2 + 20px));
  padding-right: max(20px, env(safe-area-inset-right, 0px), calc((100vw - var(--maxw)) / 2 + 20px));
}
.slide { scroll-snap-align: start; flex: none; width: min(380px, 82vw); }
.sl {
  display: flex; flex-direction: column; height: 100%; text-decoration: none; border-radius: var(--r); overflow: hidden;
  background: var(--card); border: 1px solid var(--line); transition: transform .25s cubic-bezier(.2,.8,.2,1), border-color .2s;
}
.sl:hover, .sl:focus-visible { transform: translateY(-4px); border-color: var(--accent); }
.sl-vis {
  position: relative; aspect-ratio: 16 / 10; max-width: 100%; overflow: hidden;
  display: flex; flex-direction: column; justify-content: flex-end; padding: 18px; gap: 4px;
}
.sl-img { background: #15170F; }
.sl-img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: top left; transition: transform .6s cubic-bezier(.2,.8,.2,1); }
.sl:hover .sl-img img { transform: scale(1.04); }
.sl-img::after { content: ""; position: absolute; inset: 0; background: linear-gradient(0deg, rgba(10, 12, 8, .7), transparent 45%); }
.sl-img .sl-small { position: relative; z-index: 1; color: #E8F0D6; }
/* Generative panel: lime contour lines on graphite, same in both themes */
.sl-art { background: radial-gradient(90% 80% at 85% 10%, #2A3313, transparent 70%), #121410; color: #C6F432; }
.sl-svg { position: absolute; inset: 0; width: 100%; height: 100%; transition: transform .8s cubic-bezier(.2,.8,.2,1); }
.sl-orb { fill: #C6F432; opacity: .92; }
.sl:hover .sl-svg { transform: scale(1.05) translateY(-4px); }
.sl-art::after { content: ""; position: absolute; inset: 0; background: linear-gradient(0deg, rgba(14, 16, 11, .92) 8%, rgba(14, 16, 11, .25) 60%, transparent); }
.sl-art .sl-big, .sl-art .sl-small { position: relative; z-index: 1; }
.sl-big { font: 800 clamp(1.7rem, 3.2vw, 2.4rem)/1 var(--f-display); letter-spacing: -0.035em; color: #F3F6EA; text-wrap: balance; }
.sl-small { color: #C6F432; text-transform: uppercase; letter-spacing: .06em; font-size: 0.68rem; max-width: 92%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* Section backdrop: soft lime glow + dot grid */
.latest {
  position: relative;
  background:
    radial-gradient(50% 70% at 8% 0%, color-mix(in srgb, var(--pop) 22%, transparent), transparent 70%),
    radial-gradient(45% 60% at 95% 100%, color-mix(in srgb, var(--pop) 14%, transparent), transparent 70%),
    radial-gradient(circle, color-mix(in srgb, var(--ink) 13%, transparent) 1px, transparent 1.4px) 0 0 / 22px 22px,
    var(--paper-2);
  border-block: 1px solid var(--line);
}
.latest .sl { box-shadow: 0 1px 0 var(--line), 0 18px 40px -24px rgba(0, 0, 0, .35); }
.sl-t { text-wrap: balance; }
/* What I do */
.dos { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 14px; }
.do { border: 1px solid var(--line); border-radius: var(--r); background: var(--card); padding: 22px; position: relative; overflow: hidden; }
.do::before { content: ""; position: absolute; left: 0; top: 0; width: 44px; height: 4px; background: var(--pop); }
.do h3 { margin: 0 0 10px; font: 700 1.15rem/1.2 var(--f-display); letter-spacing: -0.015em; }
.do p { margin: 0; color: var(--muted); line-height: 1.6; font-size: 0.95rem; }
.do a { color: var(--accent); text-underline-offset: 3px; }
#what-i-do .sec-head h2 { text-wrap: balance; }
/* FAQ */
.faq { display: grid; gap: 10px; max-width: 860px; }
.faq details { border: 1px solid var(--line); border-radius: var(--r); background: var(--card); padding: 0 20px; }
.faq details[open] { border-color: var(--accent); }
.faq summary { cursor: pointer; list-style: none; padding: 16px 28px 16px 0; position: relative; font: 700 1.08rem/1.3 var(--f-display); letter-spacing: -0.01em; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 0; top: 50%; translate: 0 -50%; font: 500 1.3rem/1 var(--f-mono); color: var(--accent); }
.faq details[open] summary::after { content: "–"; }
.faq p { margin: 0 0 18px; color: var(--muted); line-height: 1.6; }
.sl-body { display: flex; flex-direction: column; gap: 8px; padding: 18px 20px 20px; flex: 1; }
.sl-meta { display: flex; align-items: center; gap: 10px; color: var(--muted); }
.sl-kind { padding: 4px 8px; border-radius: 6px; background: var(--paper-2); color: var(--ink); text-transform: uppercase; letter-spacing: .05em; font-size: 0.66rem; }
.sl-k-publication, .sl-k-patent { background: var(--pop); color: var(--pop-ink); }
.sl-k-internship, .sl-k-competition { background: var(--ink); color: var(--paper); }
.sl-t { font: 700 1.25rem/1.15 var(--f-display); letter-spacing: -0.02em; }
.sl-d { color: var(--muted); font-size: 0.95rem; line-height: 1.5; }
.sl-go { margin-top: auto; padding-top: 6px; display: inline-flex; align-items: center; gap: 6px; font-weight: 600; color: var(--accent); font-size: 0.92rem; }
.sl:hover .sl-go .i { transform: translate(2px, -2px); }
.car-progress { position: relative; height: 3px; background: var(--line); border-radius: 3px; margin-top: 22px; overflow: hidden; }
.car-progress span { position: absolute; top: 0; bottom: 0; left: 0; width: 20%; background: var(--accent); border-radius: 3px; transition: left .2s linear, width .2s; }

/* ── certificates ──────────────────────── */
.cert-group { margin: 28px 0 12px; }
.cert-group:first-of-type { margin-top: 0; }
.certs { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr)); gap: 14px; }
.cert-card {
  all: unset; box-sizing: border-box; cursor: pointer; display: flex; flex-direction: column; height: 100%; width: 100%;
  border: 1px solid var(--line); border-radius: var(--r); background: var(--card); overflow: hidden;
  transition: transform .2s cubic-bezier(.2,.8,.2,1), border-color .2s;
}
.cert-noimg .cert-card { cursor: default; border-style: dashed; }
button.cert-card:hover, button.cert-card:focus-visible { transform: translateY(-3px); border-color: var(--accent); }
button.cert-card:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.cert-thumb { display: block; aspect-ratio: 4 / 3; max-width: 100%; background: var(--paper-2); overflow: hidden; border-bottom: 1px solid var(--line); }
.cert-thumb img { width: 100%; height: 100%; object-fit: cover; object-position: top center; transition: transform .4s cubic-bezier(.2,.8,.2,1); }
button.cert-card:hover .cert-thumb img { transform: scale(1.04); }
.cert-body { display: flex; flex-direction: column; gap: 6px; padding: 14px 16px 16px; }
.cert-n { font-weight: 600; line-height: 1.35; }
.cert-by { color: var(--muted); }
.dbody .certs { margin-top: 4px; }

.viewer {
  border: none; padding: 0; background: transparent; max-width: min(1100px, calc(100vw - 32px)); width: 100%;
  max-height: calc(100vh - 32px); color: var(--ink);
}
.viewer::backdrop { background: color-mix(in srgb, var(--paper) 40%, rgba(0, 0, 0, .75)); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.viewer-in { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 16px; display: grid; gap: 14px; max-height: calc(100vh - 32px); overflow: auto; }
.viewer-head { display: flex; justify-content: space-between; gap: 16px; align-items: start; }
.viewer-t { margin: 0; font: 700 1.15rem/1.25 var(--f-display); }
.viewer-m { margin: 4px 0 0; color: var(--muted); }
.viewer img { width: 100%; height: auto; border-radius: 8px; border: 1px solid var(--line); background: #fff; }
.viewer-links { display: flex; flex-wrap: wrap; gap: 8px; }

/* ── resume + about ────────────────────── */
.cv-pill {
  display: inline-flex; align-items: center; height: 38px; padding: 0 14px; border-radius: 999px; text-decoration: none;
  font-weight: 600; font-size: 0.9rem; background: var(--pop); color: var(--pop-ink); border: 1px solid var(--pop);
}
.cv-pill:hover { border-color: var(--ink); }
.cv-ext { font: 500 0.7rem var(--f-mono); opacity: .7; margin-left: 4px; }
.portrait-frame img { object-position: center bottom; filter: drop-shadow(0 8px 18px rgba(0, 0, 0, .18)); }
.about { display: grid; gap: 28px; }
.about-grid { display: grid; grid-template-columns: minmax(0, 320px) minmax(0, 1fr); gap: 28px; align-items: start; }
.cv-card {
  display: flex; flex-direction: column; gap: 8px; padding: 22px; border-radius: var(--r); text-decoration: none;
  background: var(--pop); color: var(--pop-ink); border: 1px solid var(--pop); transition: transform .2s cubic-bezier(.2,.8,.2,1);
}
.cv-card:hover { transform: translateY(-3px); }
.cv-card .eyebrow, .cv-card .sl-go { color: var(--pop-ink); }
.cv-card-t { font: 800 1.6rem/1.1 var(--f-display); letter-spacing: -0.03em; }
.cv-card-d { opacity: .8; }
.skills h2 { font-size: 1.5rem; margin-bottom: 14px; }
.skills dl { margin: 0; display: grid; gap: 0; }
.skills dl > div { display: grid; grid-template-columns: 150px minmax(0, 1fr); gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); align-items: baseline; }
.skills dt { font: 0.72rem/1.8 var(--f-mono); text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.skills dd { margin: 0; }
.skills .chips { margin: 0; }
@media (max-width: 720px) {
  .about-grid { grid-template-columns: minmax(0, 1fr); }
  .skills dl > div { grid-template-columns: minmax(0, 1fr); gap: 6px; }
  .cv-ext { display: none; }
  .cv-pill { padding: 0 12px; }
}

/* ── phone polish ──────────────────────── */
.m-short { display: none; }
@media (max-width: 720px) {
  body { font-size: 16px; }
  .top-in { gap: 12px; height: 58px; }
  .nav { top: 58px; }
  .hero-in { padding-block: 28px 20px; gap: 22px; }
  .hero-portrait { grid-template-columns: auto minmax(0, 1fr); align-items: end; justify-items: start; gap: 14px; }
  .portrait-frame { width: 116px; transform: rotate(-2deg); box-shadow: 0 0 0 3px color-mix(in srgb, var(--paper) 70%, transparent), 7px 7px 0 3px var(--pop); }
  .hero-portrait figcaption { font-size: 0.7rem; }
  .hero-eye { font-size: 0.68rem; padding: 6px 10px; }
  .hero-name { font-size: 15.2vw; margin: 16px 0 6px -0.03em; }
  .hero-is { font-size: 1.3rem; margin-bottom: 14px; }
  .hero-lede { font-size: 1.02rem; }
  .hero-cta { gap: 8px; margin-top: 20px; }
  .hero-cta .btn { padding: 10px 14px; font-size: 0.9rem; }
  .hero-cta .btn-pop { flex-basis: 100%; justify-content: center; }
  .hero-foot { padding-bottom: 18px; }
  .hero-fig { font-size: 0.66rem; }
  .sec { padding-block: 44px 0; }
  .sec-head h2 { font-size: 1.7rem; }
  .car-btn { width: 38px; height: 38px; }
  .slide { width: 84vw; }
  .sl-vis { aspect-ratio: 16 / 8; padding: 14px; }
  .quote blockquote p { font-size: 1.5rem; }
  .quote figcaption .more { margin-left: 0; flex-basis: 100%; }
  .hub { padding: 16px 4px; gap: 10px; }
  .hub-l { font-size: 2rem; }
  .m-long { display: none; }
  .m-short { display: inline; }
  .col:first-child .m-long { display: inline; }
  .col:first-child .m-short { display: none; }
  .phead { padding-block: 32px 4px; }
  .phead h1 { font-size: clamp(2.4rem, 12vw, 3.4rem); }
  .dhead h1 { font-size: clamp(2.1rem, 10vw, 3rem); }
  .irow { padding: 18px 4px; }
  .irow-t { font-size: 1.25rem; }
  .irow-d { font-size: 0.95rem; }
  .dmeta > dl > div { grid-template-columns: 110px minmax(0, 1fr); }
  .dsum { font-size: 1.08rem; }
  .hl li { padding-left: 34px; }
  .certs { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .cert-body { padding: 10px 12px 12px; gap: 4px; }
  .cert-n { font-size: 0.86rem; }
  .cert-by { font-size: 0.66rem; }
  .cert-noimg { grid-column: span 2; }
  .viewer-in { padding: 12px; }
  .foot { padding-block: 36px 28px; }
  .foot-mail { font-size: 1.35rem; }
  .foot-links { flex-wrap: wrap; gap: 10px 18px; }
  .pn b { font-size: 1.1rem; }
  .btn { padding: 10px 14px; }
}
@media (hover: none) {
  .fcard:hover, .sl:hover, button.cert-card:hover { transform: none; }
}
