/* aprameyacv.com: minimal paper theme, with a dark variant. One accent, off-black ink, Geist + Geist Mono. */
:root {
  --bg: #f3f1eb;
  --surface: #faf9f5;
  --ink: #14140f;
  --muted: #6b675c;
  --faint: #6f6b60;
  --rule: #d8d3c6;
  --rule-soft: #e6e2d6;
  --accent: #1e4b3d;
  --accent-soft: #e2e8e1;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  --sans: "Geist", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "Geist Mono", ui-monospace, "SF Mono", Menlo, monospace;
  --wrap: 1240px;
  --pad: clamp(20px, 4vw, 48px);
  --on-accent: #ffffff; --text-2: #3a3830; --text-3: #2c2b25; --code-bg: #e9e5d9; --frame: #ece8dc; --dots: #cfc9ba;
  --fine: #bdb6a2; --bar-bg: rgba(243, 241, 235, 0.82); --glass: rgba(250, 249, 245, .82); --hl: rgba(255, 255, 255, .6);
  color-scheme: light;
}
:root[data-theme="dark"] {
  --bg: #11130f; --surface: #181a15; --ink: #ecebe4; --muted: #a6a296; --faint: #8f8b7f; --rule: #2e3029; --rule-soft: #23251f;
  --accent: #86c0a6; --accent-soft: #1f2b25; --on-accent: #0d130f; --text-2: #cfcdc2; --text-3: #d8d6cb; --code-bg: #23261f;
  --frame: #1d1f1a; --dots: #3a3d35; --fine: #5b5e53; --bar-bg: rgba(17, 19, 15, 0.82); --glass: rgba(24, 26, 21, .82); --hl: rgba(255, 255, 255, .04);
  color-scheme: dark;
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 84px; -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: var(--sans); font-size: 16px; line-height: 1.65;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
img, svg { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration-color: var(--rule); text-underline-offset: 3px; transition: color .2s var(--ease), text-decoration-color .2s var(--ease); }
a:hover { text-decoration-color: var(--accent); color: var(--accent); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }
.mono { font-family: var(--mono); font-feature-settings: "tnum" 1; letter-spacing: -0.01em; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--pad); }
.skip { position: absolute; left: 16px; top: -48px; background: var(--ink); color: var(--bg); padding: 8px 14px; border-radius: 8px; z-index: 100; transition: top .2s var(--ease); }
.skip:focus { top: 12px; }
.ico { flex: none; }

/* progress + nav */
.progress { position: fixed; inset: 0 0 auto 0; height: 2px; z-index: 60; pointer-events: none; }
.progress i { display: block; height: 100%; background: var(--accent); transform: scaleX(0); transform-origin: left; }
.bar { position: sticky; top: 0; z-index: 50; background: var(--bar-bg); backdrop-filter: saturate(1.4) blur(14px); -webkit-backdrop-filter: saturate(1.4) blur(14px); border-bottom: 1px solid var(--rule-soft); box-shadow: inset 0 -1px 0 var(--hl); }
.bar-in { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--pad); height: 60px; display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 24px; }
.mark { display: inline-flex; align-items: center; gap: 10px; font-weight: 600; font-size: 17px; letter-spacing: -0.02em; text-decoration: none; }
.mark-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); }
.links { display: flex; justify-content: center; gap: 28px; font-size: 14px; color: var(--muted); }
.links a { text-decoration: none; padding: 6px 0; position: relative; }
.links a::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: var(--accent); transform: scaleX(0); transform-origin: left; transition: transform .35s var(--ease); }
.links a:hover, .links a.is-active { color: var(--ink); }
.links a:hover::after, .links a.is-active::after { transform: scaleX(1); }
.pill { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 500; text-decoration: none; padding: 8px 14px; border: 1px solid var(--rule); border-radius: 999px; background: var(--surface); transition: transform .2s var(--ease), border-color .2s var(--ease), background .2s var(--ease); }
.pill:hover { border-color: var(--accent); color: var(--accent); }
.pill:active { transform: translateY(1px) scale(.98); }

/* shared type */
h1, h2, h3 { margin: 0; font-weight: 500; letter-spacing: -0.035em; line-height: 1.08; }
h1 { font-size: clamp(2.2rem, 4.4vw, 3.6rem); }
h2 { font-size: clamp(1.6rem, 2.6vw, 2.1rem); }
p { margin: 0 0 1em; }
.eyebrow { display: flex; align-items: center; gap: 10px; margin: 0 0 18px; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.lede { font-size: 1.1rem; color: var(--muted); max-width: 62ch; }
.muted { color: var(--muted); max-width: 34ch; font-size: .95rem; }
.live { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); position: relative; }
.live::after { content: ""; position: absolute; inset: -4px; border-radius: 50%; border: 1px solid var(--accent); opacity: 0; animation: ping 2.4s var(--ease) infinite; }
@keyframes ping { 0% { transform: scale(.6); opacity: .7; } 80%, 100% { transform: scale(1.5); opacity: 0; } }

/* buttons */
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.btn { display: inline-flex; align-items: center; gap: 8px; padding: 12px 20px; border-radius: 999px; background: var(--ink); color: var(--bg); text-decoration: none; font-size: 14.5px; font-weight: 500; border: 1px solid var(--ink); transition: transform .25s var(--ease), background .25s var(--ease), color .25s var(--ease); will-change: transform; }
.btn:hover { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.btn:active { transform: translateY(1px) scale(.98); }
.btn.ghost { background: transparent; color: var(--ink); border-color: var(--rule); }
.btn.ghost:hover { border-color: var(--accent); color: var(--accent); background: transparent; }

/* hero */
.hero { min-height: calc(100dvh - 60px); display: flex; flex-direction: column; justify-content: center; position: relative; padding: clamp(40px, 8vh, 96px) 0 72px; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(32px, 6vw, 88px); align-items: center; width: 100%; }
.hero h1.name { font-size: clamp(3.4rem, 8.6vw, 7.4rem); letter-spacing: -0.055em; line-height: .92; max-width: none; margin-bottom: 26px; font-weight: 500; }
.hero h1.name span { color: var(--accent); }
.role { font-size: clamp(1.2rem, 2.1vw, 1.6rem); letter-spacing: -0.025em; line-height: 1.3; max-width: 28ch; margin: 0 0 18px; }
.about { max-width: 66ch; }
.about p { color: var(--text-2); }
.about .about-lead { font-size: 1.25rem; letter-spacing: -0.02em; line-height: 1.5; color: var(--ink); margin-bottom: 1.2em; }
.facts { display: grid; grid-template-columns: repeat(3, auto); justify-content: start; gap: 8px 36px; margin: 40px 0 0; padding-top: 22px; border-top: 1px solid var(--rule); }
.facts dt { font-size: 11px; text-transform: uppercase; letter-spacing: .08em; color: var(--faint); }
.facts dd { margin: 2px 0 0; font-size: 14px; }
.scrollcue { position: absolute; left: var(--pad); bottom: 22px; display: inline-flex; align-items: center; gap: 8px; font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--faint); text-decoration: none; }
.scrollcue .ico { animation: nudge 2.2s var(--ease) infinite; }
@keyframes nudge { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(3px); } }

/* ledger */
.ledger { background: var(--surface); border: 1px solid var(--rule); border-radius: 20px; padding: 26px 26px 18px; box-shadow: 0 24px 48px -28px rgba(20, 20, 15, .14), inset 0 1px 0 var(--hl); }
.ledger-head { display: flex; justify-content: space-between; align-items: center; font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); padding-bottom: 14px; border-bottom: 1px solid var(--rule-soft); }
.ledger-key { display: inline-flex; align-items: center; gap: 6px; text-transform: none; letter-spacing: 0; }
.ledger-key i { width: 18px; height: 4px; border-radius: 2px; display: inline-block; }
.ledger-key .k0 { background: var(--fine); }
.ledger-key .k1 { background: var(--accent); margin-left: 8px; }
.ledger ul { list-style: none; margin: 0; padding: 0; }
.lrow { padding: 16px 0; border-bottom: 1px solid var(--rule-soft); display: grid; grid-template-columns: 1fr auto; gap: 8px 16px; }
.lrow:last-child { border-bottom: 0; }
.lname { font-weight: 500; display: block; }
.llabel { font-size: 12.5px; color: var(--muted); display: block; }
.lvals { display: flex; align-items: baseline; gap: 8px; font-size: 14px; }
.lvals .from { color: var(--faint); text-decoration: line-through; text-decoration-color: var(--rule); }
.lvals .to { color: var(--accent); font-weight: 500; font-size: 18px; }
.lvals .to::before { content: "\2192"; color: var(--faint); font-weight: 400; margin-right: 8px; font-size: 13px; }
.lvals .to.flat::before { content: ""; margin: 0; }
.lbars { grid-column: 1 / -1; display: grid; gap: 4px; }
.lbars i { display: block; height: 4px; border-radius: 2px; transform-origin: left; transform: scaleX(0); transition: transform 1.2s var(--ease) calc(var(--i, 0) * 120ms + 250ms); }
.lbars .b0 { background: var(--fine); }
.lbars .b1 { background: var(--accent); }
.lrow.in .lbars i { transform: scaleX(var(--s)); }
.ledger-foot { margin: 12px 0 0; font-size: 11px; color: var(--faint); }

/* result band */
.band { border-block: 1px solid var(--rule); background: var(--surface); }
.band-grid { display: grid; grid-template-columns: repeat(4, 1fr); }
.bcell { padding: 34px 24px 30px; border-left: 1px solid var(--rule-soft); display: flex; flex-direction: column; gap: 10px; }
.bcell:first-child { border-left: 0; padding-left: 0; }
.bcell b { font-size: clamp(2rem, 3.4vw, 2.9rem); font-weight: 500; letter-spacing: -0.04em; line-height: 1; color: var(--accent); }
.bcell span { font-size: 14px; color: var(--muted); max-width: 26ch; }
.bcell em { font-style: normal; font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--faint); margin-top: auto; }

/* sections */
.sec { padding: clamp(64px, 10vw, 128px) 0 0; }
.sec:last-of-type { padding-bottom: clamp(64px, 10vw, 128px); }
.sec-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 20px; margin-bottom: 28px; }
.split { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: clamp(28px, 6vw, 96px); }
.split-l { position: sticky; top: 96px; align-self: start; }
.split-l h2 { margin-bottom: 14px; }
.note { margin-top: 26px; font-size: 14px; color: var(--muted); }
.note a { color: var(--ink); }

/* filter chips */
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { font: 500 13px var(--sans); padding: 7px 14px; border-radius: 999px; border: 1px solid var(--rule); background: transparent; color: var(--muted); cursor: pointer; transition: transform .2s var(--ease), background .2s var(--ease), color .2s var(--ease), border-color .2s var(--ease); }
.chip:hover { border-color: var(--accent); color: var(--accent); }
.chip:active { transform: scale(.97); }
.chip.is-on { background: var(--ink); border-color: var(--ink); color: var(--bg); }

/* work index */
.wlist { border-top: 1px solid var(--rule); }
.wrow { display: grid; grid-template-columns: 56px minmax(0, 1fr) minmax(130px, auto) 28px; gap: 20px; align-items: center; padding: 30px 8px; border-bottom: 1px solid var(--rule); text-decoration: none; position: relative; transition: background .35s var(--ease), padding .35s var(--ease); }
.wrow::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 2px; background: var(--accent); transform: scaleY(0); transition: transform .35s var(--ease); }
.wrow:hover { background: var(--surface); padding-left: 20px; color: inherit; }
.wrow:hover::before { transform: scaleY(1); }
.wrow[hidden] { display: none; }
.widx { font-size: 12px; color: var(--faint); }
.wmain { display: grid; gap: 4px; }
.wtitle { font-size: clamp(1.25rem, 2vw, 1.6rem); font-weight: 500; letter-spacing: -0.03em; line-height: 1.15; }
.wdesc { color: var(--muted); font-size: 15px; max-width: 56ch; }
.wstack { font-size: 11.5px; color: var(--faint); letter-spacing: 0; }
.wmetric { text-align: right; display: grid; gap: 2px; }
.wmetric b { font-size: 1.5rem; font-weight: 500; letter-spacing: -0.04em; color: var(--accent); line-height: 1; }
.wmetric i { font-style: normal; font-size: 11px; color: var(--faint); text-transform: uppercase; letter-spacing: .06em; }
.wgo { color: var(--faint); transition: transform .35s var(--ease), color .35s var(--ease); }
.wrow:hover .wgo { color: var(--accent); transform: translate(3px, -3px); }
.empty { color: var(--muted); padding: 26px 0; }

/* method */
.mgrid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 36px; border-top: 1px solid var(--rule); }
.mitem { padding: 26px 0 30px; border-bottom: 1px solid var(--rule); }
.mno { font-size: 12px; color: var(--accent); display: block; margin-bottom: 12px; }
.mitem h3 { font-size: 1.15rem; margin-bottom: 10px; letter-spacing: -0.02em; }
.mitem p { color: var(--muted); font-size: 15px; margin: 0; max-width: 42ch; }

/* experience */
.xlist { border-top: 1px solid var(--rule); }
.xrow { display: grid; grid-template-columns: 150px minmax(0, 1fr); gap: 24px; padding: 28px 0; border-bottom: 1px solid var(--rule); }
.xwhen { font-size: 12px; color: var(--muted); padding-top: 5px; }
.xbody h3 { font-size: 1.2rem; letter-spacing: -0.02em; margin-bottom: 14px; }
.xbody h3 span { color: var(--muted); font-weight: 400; }
.xbody ul { margin: 0; padding-left: 18px; color: var(--text-2); font-size: 15px; }
.xbody li { margin: 0 0 9px; padding-left: 4px; }
.xbody li::marker { color: var(--accent); }

/* stack */
.slist { border-top: 1px solid var(--rule); }
.srow { display: grid; grid-template-columns: 190px minmax(0, 1fr); gap: 24px; padding: 20px 0; border-bottom: 1px solid var(--rule); }
.srow h3 { font-size: 1rem; letter-spacing: -0.02em; padding-top: 2px; }
.srow p { margin: 0; font-size: 13px; color: var(--muted); line-height: 1.75; }

/* education */
.edu h3 { font-size: 1.2rem; letter-spacing: -0.02em; margin-bottom: 8px; }
.edu h3 span { color: var(--muted); font-weight: 400; }
.edu-meta { font-size: 12px; color: var(--accent); margin-bottom: 16px; }
.edu p:last-child { color: var(--text-2); max-width: 58ch; }

/* contact */
.contact { border-top: 1px solid var(--rule); margin-top: clamp(64px, 10vw, 128px); }
.contact-h { font-size: clamp(2rem, 4vw, 3.2rem); max-width: 18ch; margin-bottom: 18px; }
.mailrow { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; margin: 28px 0 8px; }
.mail { font-size: clamp(1.05rem, 2.4vw, 1.6rem); text-decoration: none; border-bottom: 1px solid var(--rule); padding-bottom: 2px; }
.mail:hover { border-color: var(--accent); }
.copy { display: inline-flex; align-items: center; gap: 8px; font: 500 13px var(--sans); padding: 8px 14px; border-radius: 999px; border: 1px solid var(--rule); background: var(--surface); color: var(--ink); cursor: pointer; transition: transform .2s var(--ease), border-color .2s var(--ease); }
.copy:hover { border-color: var(--accent); color: var(--accent); }
.copy:active { transform: translateY(1px) scale(.98); }
.clinks { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; margin-top: 48px; border-top: 1px solid var(--rule); }
.clinks a { display: flex; flex-direction: column; gap: 6px; padding: 20px 20px 22px 0; text-decoration: none; font-size: 15px; border-bottom: 1px solid var(--rule); position: relative; }
.clinks a span { font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--faint); }
.clinks a .ico { position: absolute; right: 18px; top: 22px; color: var(--faint); transition: transform .3s var(--ease), color .3s var(--ease); }
.clinks a:hover .ico { transform: translate(2px, -2px); color: var(--accent); }
.foot { border-top: 1px solid var(--rule); padding: 22px 0; font-size: 13px; color: var(--muted); }
.foot-in { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px 24px; }
.toast { position: fixed; left: 50%; bottom: 28px; transform: translate(-50%, 16px); opacity: 0; pointer-events: none; background: var(--ink); color: var(--bg); font-size: 13px; padding: 10px 16px; border-radius: 999px; transition: opacity .3s var(--ease), transform .3s var(--ease); z-index: 70; }
.toast.on { opacity: 1; transform: translate(-50%, 0); }

/* project page */
.phead { padding: clamp(40px, 7vw, 88px) 0 40px; border-bottom: 1px solid var(--rule); }
.crumb { display: flex; gap: 10px; font-size: 12px; color: var(--faint); margin-bottom: 22px; }
.crumb a { text-decoration: none; color: var(--muted); }
.phead h1 { font-size: clamp(2.4rem, 5vw, 4rem); margin-bottom: 12px; }
.ptag { font-size: clamp(1.1rem, 2vw, 1.4rem); letter-spacing: -0.02em; color: var(--accent); margin: 0 0 14px; }
.psub { color: var(--muted); max-width: 62ch; font-size: 1.05rem; }
.ptags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 20px; }
.tag { font-size: 11.5px; padding: 5px 11px; border-radius: 999px; border: 1px solid var(--rule); color: var(--muted); }
.pgrid { display: grid; grid-template-columns: 280px minmax(0, 1fr); gap: clamp(32px, 6vw, 80px); padding-top: 44px; padding-bottom: 96px; }
.prail-in { position: sticky; top: 92px; display: grid; gap: 30px; }
.pstats { display: grid; gap: 0; border-top: 1px solid var(--rule); }
.pstat { padding: 14px 0; border-bottom: 1px solid var(--rule-soft); display: grid; gap: 2px; }
.pstat b { font-size: 1.45rem; font-weight: 500; letter-spacing: -0.04em; color: var(--accent); }
.pstat span { font-size: 12.5px; color: var(--muted); }
.toc { display: grid; gap: 2px; }
.toc span { font-size: 11px; text-transform: uppercase; letter-spacing: .08em; color: var(--faint); margin-bottom: 8px; }
.toc a { font-size: 14px; color: var(--muted); text-decoration: none; padding: 5px 0 5px 12px; border-left: 1px solid var(--rule); transition: color .2s var(--ease), border-color .2s var(--ease); }
.toc a:hover, .toc a.is-active { color: var(--ink); border-color: var(--accent); }
.rlinks { display: grid; gap: 8px; }
.rlink { display: inline-flex; align-items: center; justify-content: space-between; gap: 8px; padding: 10px 14px; border: 1px solid var(--rule); border-radius: 12px; text-decoration: none; font-size: 14px; background: var(--surface); transition: transform .2s var(--ease), border-color .2s var(--ease); }
.rlink:hover { border-color: var(--accent); color: var(--accent); }
.rlink:active { transform: translateY(1px) scale(.99); }
.pbody { min-width: 0; }
.pblock { padding: 0 0 52px; }
.pblock h2 { display: flex; align-items: baseline; gap: 14px; margin-bottom: 18px; padding-top: 6px; border-top: 1px solid var(--rule); padding-top: 22px; }
.pblock h2 .mono { font-size: 12px; color: var(--accent); font-weight: 400; letter-spacing: 0; }
.prose { max-width: 70ch; color: var(--text-3); }
.prose p { margin: 0 0 1em; }
.prose ul { padding-left: 20px; margin: 0 0 1em; }
.prose li { margin: 0 0 .7em; }
.prose li::marker { color: var(--accent); }
.prose strong { font-weight: 500; color: var(--ink); }
.prose .small, .small { font-size: 13.5px; color: var(--muted); }
.prose code, .prose .mono { font-family: var(--mono); font-size: .88em; background: var(--code-bg); padding: 1px 6px; border-radius: 4px; }
.prose table { width: 100%; max-width: none; border-collapse: collapse; margin: 18px 0 8px; font-size: 14px; display: block; overflow-x: auto; }
.prose th { text-align: left; font: 500 11px var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--muted); border-bottom: 1px solid var(--rule); padding: 10px 14px 10px 0; white-space: nowrap; }
.prose td { padding: 12px 14px 12px 0; border-bottom: 1px solid var(--rule-soft); white-space: nowrap; }
.prose td:first-child { white-space: normal; min-width: 150px; }
.prose .num { text-align: right; font-family: var(--mono); font-variant-numeric: tabular-nums; }
.pend { padding-top: 12px; }
.report-cta { display: inline-flex; align-items: center; gap: 10px; padding: 14px 22px; background: var(--ink); color: var(--bg); border-radius: 999px; text-decoration: none; font-weight: 500; transition: background .25s var(--ease), transform .25s var(--ease); }
.report-cta:hover { background: var(--accent); color: var(--on-accent); }
.report-cta:active { transform: translateY(1px) scale(.98); }
.pnav { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 56px; border-top: 1px solid var(--rule); padding-top: 24px; }
.pnav a { display: flex; align-items: center; gap: 14px; text-decoration: none; font-size: 1.1rem; font-weight: 500; letter-spacing: -0.02em; padding: 10px 0; }
.pnav a.r { justify-content: flex-end; text-align: right; }
.pnav i { display: block; font-style: normal; font-size: 11px; text-transform: uppercase; letter-spacing: .08em; color: var(--faint); font-weight: 400; margin-bottom: 2px; }
.pnav a .ico { color: var(--faint); transition: transform .3s var(--ease), color .3s var(--ease); }
.pnav a:hover .ico { color: var(--accent); transform: translateX(-3px); }
.pnav a.r:hover .ico { transform: translate(3px, -3px); }

.nf { min-height: calc(100dvh - 60px); }

/* reveal */
.reveal { opacity: 0; transform: translateY(16px); transition: opacity .8s var(--ease) calc(var(--i, 0) * 70ms), transform .8s var(--ease) calc(var(--i, 0) * 70ms); }
.reveal.in { opacity: 1; transform: none; }

/* responsive */
@media (max-width: 980px) {
  .hero { min-height: auto; padding-top: 48px; }
  .hero-grid { grid-template-columns: 1fr; }
  .scrollcue { display: none; }
  .band-grid { grid-template-columns: 1fr 1fr; }
  .bcell:nth-child(3) { border-left: 0; padding-left: 0; }
  .bcell { border-top: 1px solid var(--rule-soft); }
  .bcell:nth-child(-n+2) { border-top: 0; }
  .split { grid-template-columns: 1fr; }
  .split-l { position: static; }
  .mgrid { grid-template-columns: 1fr; }
  .clinks { grid-template-columns: 1fr 1fr; }
  .pgrid { grid-template-columns: 1fr; }
  .prail-in { position: static; }
  .toc { display: none; }
  .links { display: none; }
  .bar-in { grid-template-columns: 1fr auto; }
}
@media (max-width: 620px) {
  .facts { grid-template-columns: 1fr; }
  .wrow { grid-template-columns: 1fr auto; padding: 24px 0; }
  .widx, .wgo { display: none; }
  .wrow:hover { padding-left: 0; }
  .wmetric { grid-column: 2; grid-row: 1; }
  .wmain { grid-column: 1; }
  .xrow, .srow { grid-template-columns: 1fr; gap: 8px; }
  .clinks { grid-template-columns: 1fr; }
  .band-grid { grid-template-columns: 1fr; }
  .bcell { border-left: 0; padding-left: 0; border-top: 1px solid var(--rule-soft); }
  .bcell:first-child { border-top: 0; }
  .pnav { grid-template-columns: 1fr; }
  .pnav a.r { justify-content: flex-start; text-align: left; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition-duration: .01ms !important; transition-delay: 0s !important; }
  .reveal { opacity: 1; transform: none; }
  .lbars i { transform: scaleX(var(--s)); }
}

.lvals .to.big { font-size: clamp(1.7rem, 2.6vw, 2.2rem); letter-spacing: -0.04em; line-height: 1; }
.lvals .to.big::before { content: ""; margin: 0; }
.ledger .lrow { align-items: center; }
.band-eyebrow { padding-top: 26px; margin-bottom: 0; }
.band .bcell { padding-top: 22px; }

/* portrait */
.portrait { margin: 0; position: relative; justify-self: end; width: min(100%, 360px); }
.portrait img { width: 100%; height: auto; aspect-ratio: 3 / 4; object-fit: cover; object-position: 50% 12%; border-radius: 20px; border: 1px solid var(--rule); background: var(--surface); box-shadow: 0 24px 48px -28px rgba(20, 20, 15, .22); }
.portrait figcaption { position: absolute; left: 14px; bottom: 14px; display: inline-flex; align-items: center; gap: 8px; padding: 7px 12px; border-radius: 999px; font-size: 11.5px; color: var(--ink); background: var(--glass); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border: 1px solid var(--hl); }
/* career strip */
.cstrip { display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); margin-bottom: 8px; }
.cstat { padding: 22px 16px 22px 0; display: grid; gap: 8px; align-content: start; }
.cstat + .cstat { padding-left: 16px; border-left: 1px solid var(--rule-soft); }
.cstat b { font-size: clamp(1.5rem, 2.4vw, 2rem); font-weight: 500; letter-spacing: -0.04em; color: var(--accent); line-height: 1; }
.cstat span { font-size: 12.5px; color: var(--muted); line-height: 1.45; }
.cstat em { display: block; font-style: normal; font-weight: 500; color: var(--ink); font-size: 13px; }
@media (max-width: 980px) { .portrait { justify-self: start; width: min(100%, 360px); } .cstrip { grid-template-columns: 1fr 1fr; } .cstat:nth-child(3) { padding-left: 0; border-left: 0; } .cstat:nth-child(n+3) { border-top: 1px solid var(--rule-soft); } }
@media (max-width: 520px) { .cstrip { grid-template-columns: 1fr; } .cstat + .cstat { padding-left: 0; border-left: 0; border-top: 1px solid var(--rule-soft); } }

/* small circular portrait */
.hero-grid { grid-template-columns: minmax(0, 1fr); }
.hero-copy { max-width: 860px; }
.idrow { display: flex; align-items: center; gap: 18px; margin-bottom: 28px; }
.idrow .eyebrow { margin: 0; }
.avatar { width: 88px; height: 88px; border-radius: 50%; object-fit: cover; object-position: 50% 14%; border: 2px solid var(--surface); box-shadow: 0 0 0 1px var(--rule), 0 14px 28px -14px rgba(20, 20, 15, .35); background: var(--surface); }
.hero h1.name { font-size: clamp(3.6rem, 10vw, 8.6rem); }
.hero .role { max-width: 34ch; }
.hero .lede { max-width: 58ch; }

/* medium circular portrait in the right column */
.hero-grid { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); }
.hero-copy { max-width: none; }
.hero h1.name { font-size: clamp(3.4rem, 8.6vw, 7.4rem); }
.portrait-circle { margin: 0; justify-self: center; display: grid; justify-items: center; gap: 18px; }
.portrait-circle img { width: min(100%, 300px); height: auto; aspect-ratio: 1 / 1; border-radius: 50%; object-fit: cover; object-position: 50% 14%; border: 3px solid var(--surface); box-shadow: 0 0 0 1px var(--rule), 0 30px 50px -26px rgba(20, 20, 15, .4); background: var(--surface); }
.portrait-circle figcaption { display: inline-flex; align-items: center; gap: 8px; font-size: 12px; color: var(--muted); }
@media (max-width: 980px) { .hero-grid { grid-template-columns: 1fr; } .portrait-circle { justify-self: start; order: -1; } .portrait-circle img { width: 200px; } }

/* writing */
.wrlist { border-top: 1px solid var(--rule); }
.wrrow { display: grid; grid-template-columns: 72px minmax(0, 1fr) 80px 20px; gap: 18px; align-items: baseline; padding: 20px 6px; border-bottom: 1px solid var(--rule); text-decoration: none; transition: background .3s var(--ease), padding .3s var(--ease); }
.wrrow:hover { background: var(--surface); padding-left: 14px; color: inherit; }
.wrkind { font-size: 11px; text-transform: uppercase; letter-spacing: .08em; color: var(--accent); }
.wrmain { display: grid; gap: 4px; }
.wrtitle { font-weight: 500; letter-spacing: -0.02em; line-height: 1.3; font-size: 1.02rem; }
.wrdesc { font-size: 14px; color: var(--muted); max-width: 60ch; }
.wrwhen { font-size: 11.5px; color: var(--faint); text-align: right; }
.wrgo { color: var(--faint); transition: transform .3s var(--ease), color .3s var(--ease); }
.wrrow:hover .wrgo { color: var(--accent); transform: translate(2px, -2px); }
@media (max-width: 620px) { .wrrow { grid-template-columns: 1fr auto; } .wrkind { grid-column: 1 / -1; } .wrwhen { display: none; } .wrrow:hover { padding-left: 6px; } }

/* skills with icons */
.srow { grid-template-columns: 210px minmax(0, 1fr); align-items: start; }
.srow h3 { display: flex; align-items: center; gap: 10px; font-size: 1rem; letter-spacing: -0.02em; padding-top: 4px; }
.srow h3 .sk-ico { color: var(--accent); width: 18px; height: 18px; }
.chipset { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.chipset li { display: inline-flex; align-items: center; gap: 8px; padding: 7px 12px 7px 10px; border: 1px solid var(--rule); border-radius: 999px; background: var(--surface); font-size: 13.5px; color: var(--ink); transition: transform .25s var(--ease), border-color .25s var(--ease), color .25s var(--ease); }
.chipset li .sk-ico { color: var(--muted); transition: color .25s var(--ease); }
.chipset li:hover { transform: translateY(-2px); border-color: var(--accent); }
.chipset li:hover .sk-ico { color: var(--accent); }
@media (max-width: 620px) { .srow { grid-template-columns: 1fr; gap: 12px; } }

/* smaller name, one line */
.hero h1.name { font-size: clamp(2.6rem, 5.4vw, 4.6rem); letter-spacing: -0.05em; line-height: 1; margin-bottom: 22px; }

/* papers */
.paperlist { display: grid; border-top: 1px solid var(--rule); margin: 22px 0 6px; }
.paper { display: grid; grid-template-columns: 56px minmax(0, 1fr) 20px; gap: 16px; align-items: baseline; padding: 16px 4px; border-bottom: 1px solid var(--rule); text-decoration: none; transition: background .3s var(--ease), padding .3s var(--ease); }
.paper:hover { background: var(--surface); padding-left: 12px; color: inherit; }
.paper .mono { font-size: 12px; color: var(--accent); }
.paper b { display: block; font-weight: 500; letter-spacing: -0.015em; line-height: 1.35; }
.paper i { display: block; font-style: normal; font-size: 13px; color: var(--muted); margin-top: 3px; }
.paper .ico { color: var(--faint); }
.paper:hover .ico { color: var(--accent); }

.skills-note { max-width: 42ch; margin: 0; }
#skills .srow { grid-template-columns: 240px minmax(0, 1fr); padding: 24px 0; }
@media (max-width: 760px) { #skills .srow { grid-template-columns: 1fr; gap: 14px; } }

/* screenshots */
.shots { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
.shot { margin: 0; display: grid; gap: 10px; align-content: start; }
.shot.lead { grid-column: 1 / -1; }
.shot a { display: block; border: 1px solid var(--rule); border-radius: 12px; overflow: hidden; background: var(--surface); box-shadow: 0 22px 40px -28px rgba(20, 20, 15, .25); transition: transform .35s var(--ease), box-shadow .35s var(--ease); }
.shot.lead a { border-radius: 0 0 12px 12px; border-top: 0; }
.shot a:hover { transform: translateY(-3px); box-shadow: 0 28px 48px -26px rgba(20, 20, 15, .32); }
.shot img { width: 100%; height: auto; display: block; }
.shot figcaption { font-size: 13px; color: var(--muted); }
.frame { display: flex; align-items: center; gap: 12px; padding: 10px 14px; border: 1px solid var(--rule); border-bottom: 0; border-radius: 12px 12px 0 0; background: var(--frame); margin-bottom: -10px; }
.frame .dots { display: inline-flex; gap: 6px; }
.frame .dots i { width: 9px; height: 9px; border-radius: 50%; background: var(--dots); display: block; }
.frame .url { font-size: 11.5px; color: var(--muted); background: var(--surface); border: 1px solid var(--rule-soft); border-radius: 999px; padding: 3px 12px; }
@media (max-width: 700px) { .shots { grid-template-columns: 1fr; } }

.proof { margin: 12px 0 0; font-size: 12px; color: var(--faint); }
.proof a { color: var(--muted); text-underline-offset: 3px; }
.proof a:hover { color: var(--accent); }

.frame .url { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }

/* video */
.vwrap { border: 1px solid var(--rule); border-radius: 0 0 12px 12px; border-top: 0; overflow: hidden; background: #14160f; box-shadow: 0 22px 40px -28px rgba(20, 20, 15, .35); }
.shot.vid .frame { margin-bottom: 0; }
.shot video { width: 100%; height: auto; display: block; aspect-ratio: 16 / 9; background: #14160f; }

/* theme toggle */
.bar-in { grid-template-columns: auto 1fr auto auto; }
.theme-toggle { width: 38px; height: 38px; display: inline-grid; place-items: center; border: 1px solid var(--rule); border-radius: 999px; background: var(--surface); color: var(--ink); cursor: pointer; transition: transform .2s var(--ease), border-color .2s var(--ease), color .2s var(--ease); }
.theme-toggle:hover { border-color: var(--accent); color: var(--accent); }
.theme-toggle:active { transform: scale(.94); }
.theme-toggle svg { width: 18px; height: 18px; grid-area: 1 / 1; transition: transform .45s var(--ease), opacity .3s var(--ease); }
.theme-toggle .i-moon { opacity: 1; transform: rotate(0); }
.theme-toggle .i-sun { opacity: 0; transform: rotate(-70deg) scale(.6); }
:root[data-theme="dark"] .theme-toggle .i-moon { opacity: 0; transform: rotate(70deg) scale(.6); }
:root[data-theme="dark"] .theme-toggle .i-sun { opacity: 1; transform: rotate(0) scale(1); }
@media (max-width: 980px) { .bar-in { grid-template-columns: 1fr auto auto; } }
body, .bar, .ledger, .chipset li, .pill, .rlink, .chip { transition: background-color .3s var(--ease), border-color .3s var(--ease), color .3s var(--ease); }
:root[data-theme="dark"] .shot img, :root[data-theme="dark"] .portrait-circle img, :root[data-theme="dark"] .avatar { filter: brightness(.92); }
