/* Akshath Reddy Udumula · portfolio
   Ink and copper. Inter only. Copper is used sparingly. */

:root {
  --ink: #0E0F11;
  --ink-2: #1A1C1F;
  --ink-3: #24272B;
  --stone: #8C877E;
  --cream: #EFEBE4;
  --copper: #C07A4A;
  --copper-hi: #E39A66;

  --on-1: #EFEBE4;
  --on-2: rgba(239, 235, 228, 0.68);
  --on-3: rgba(239, 235, 228, 0.46);
  --line: rgba(239, 235, 228, 0.12);

  --f: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --gutter: clamp(20px, 4vw, 56px);
  --maxw: 1240px;
  --edge: max(var(--gutter), calc((100vw - var(--maxw)) / 2));
  --nav-h: 68px;
  --ease: cubic-bezier(0.2, 0.7, 0.1, 1);
}

/* Sections marked .tone follow the page from ink to cream and back. Registering the
   colors lets them ease instead of switching. */
@property --bg { syntax: "<color>"; inherits: true; initial-value: #0E0F11; }
@property --fg { syntax: "<color>"; inherits: true; initial-value: #EFEBE4; }
@property --fg-2 { syntax: "<color>"; inherits: true; initial-value: rgba(239, 235, 228, 0.68); }
@property --fg-3 { syntax: "<color>"; inherits: true; initial-value: rgba(239, 235, 228, 0.5); }
@property --rule { syntax: "<color>"; inherits: true; initial-value: rgba(239, 235, 228, 0.13); }

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; background: var(--ink); scrollbar-gutter: stable; }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-stopped, html.is-modal { overflow: hidden; }

body { margin: 0;
  --bg: #0E0F11; --fg: #EFEBE4; --fg-2: rgba(239, 235, 228, 0.68); --fg-3: rgba(239, 235, 228, 0.5); --rule: rgba(239, 235, 228, 0.13);
  background: var(--bg);
  transition: --bg 0.9s var(--ease), --fg 0.9s var(--ease), --fg-2 0.9s var(--ease), --fg-3 0.9s var(--ease), --rule 0.9s var(--ease);
  color: var(--on-1);
  font-family: var(--f);
  font-size: 17px; line-height: 1.52; font-weight: 400;
  letter-spacing: -0.012em;
  font-optical-sizing: auto;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  /* clip, unlike hidden, never makes the body a scroller, so sticky cards hold still while a dialog locks the page */
  overflow-x: hidden; overflow-x: clip; }

h1, h2, h3, h4, p, figure, blockquote, ul, ol, dl, dd { margin: 0; }
ul, ol { padding: 0; list-style: none; }
a { color: inherit; text-decoration: none; }
img, canvas, video, svg { display: block; max-width: 100%; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
::selection { background: rgba(192, 122, 74, 0.38); color: #fff; }
:focus-visible { outline: 2px solid var(--copper); outline-offset: 3px; border-radius: 8px; }

.wrap { width: 100%; max-width: calc(var(--maxw) + var(--gutter) * 2); margin: 0 auto; padding: 0 var(--gutter); }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; }

.skip { position: absolute; left: 12px; top: -64px; z-index: 100;
  padding: 10px 16px; border-radius: 999px;
  background: var(--cream); color: var(--ink); font-size: 14px; font-weight: 500;
  transition: top 0.3s var(--ease); }
.skip:focus { top: 12px; }

.eyebrow { font-size: 15px; line-height: 1.3; font-weight: 600; letter-spacing: -0.008em; color: var(--stone); }
.dim { color: var(--stone); }

/* Light sections */
html.is-light body { --bg: #EFEBE4; --fg: #0E0F11; --fg-2: rgba(14, 15, 17, 0.72); --fg-3: rgba(14, 15, 17, 0.6); --rule: rgba(14, 15, 17, 0.14); }
.tone { color: var(--fg); }
.tone .eyebrow { color: var(--fg-3); }

/* Two tone section headlines: the second half sits back in stone */
.display { font-size: clamp(2.3rem, 4.4vw, 4.2rem); line-height: 1.04; font-weight: 600; letter-spacing: -0.034em; }
.display--m { font-size: clamp(2rem, 3.3vw, 3.2rem); line-height: 1.06; }
/* Headlines rise in line by line: each line has its own mask, with room below for the descenders */
.hl { display: block; overflow: hidden; padding-bottom: 0.14em; margin-bottom: -0.14em; }
.hl__in { display: block; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  height: 48px; padding: 0 24px; border-radius: 999px;
  font-size: 16px; line-height: 1; font-weight: 500; letter-spacing: -0.014em; white-space: nowrap;
  transition: background-color 0.3s var(--ease), color 0.3s var(--ease), box-shadow 0.3s var(--ease); }
.btn__arrow { transition: transform 0.35s var(--ease); }
.btn:hover .btn__arrow { transform: translateX(3px); }
.btn--light { background: var(--cream); color: var(--ink); }
.btn--light:hover { background: #fff; }
.btn--ghost { color: var(--on-1); background: rgba(239, 235, 228, 0.06);
  box-shadow: inset 0 0 0 1px rgba(239, 235, 228, 0.24);
  -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); }
.btn--ghost:hover { background: rgba(239, 235, 228, 0.12); box-shadow: inset 0 0 0 1px rgba(239, 235, 228, 0.44); }
.btn--sm { height: 36px; padding: 0 16px; font-size: 14px; gap: 8px; }
/* Buttons that lean toward the cursor; the label follows a little further than the button */
.is-magnetic { position: relative; }
.is-magnetic::after { content: ""; position: absolute; inset: -12px -16px; }
.mag { display: inline-flex; align-items: center; gap: inherit; }

/* Sections and tiles that rise in as they come into view */
.js [data-reveal] { opacity: 0; transform: translate3d(0, 26px, 0); }
.js [data-reveal].is-in { opacity: 1; transform: none;
  transition: opacity 0.9s var(--ease) var(--d, 0s), transform 1.1s var(--ease) var(--d, 0s); }

/* Nav */
.nav { position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  transition: background-color 0.45s var(--ease), box-shadow 0.45s var(--ease); }
.nav__in { height: var(--nav-h); display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.nav__brand { display: inline-flex; align-items: center; gap: 10px; font-size: 15.5px; font-weight: 600; letter-spacing: -0.02em; }
.nav__mark { width: 8px; height: 8px; border-radius: 2px; background: var(--copper); }
.nav__links { display: flex; gap: 32px; font-size: 14.5px; font-weight: 500; color: var(--on-2); }
.nav__links a { transition: color 0.3s var(--ease); }
.nav__links a:hover { color: var(--on-1); }
.nav.is-solid { background: rgba(14, 15, 17, 0.74);
  -webkit-backdrop-filter: saturate(140%) blur(18px); backdrop-filter: saturate(140%) blur(18px);
  box-shadow: inset 0 -1px 0 var(--line); }
.js .nav { opacity: 0; transition: opacity 0.9s var(--ease) 0.1s, background-color 0.45s var(--ease), box-shadow 0.45s var(--ease), color 0.6s var(--ease); }
.js .nav.is-ready { opacity: 1; }
html.is-light .nav.is-solid { background: rgba(239, 235, 228, 0.8); color: var(--ink); box-shadow: inset 0 -1px 0 rgba(14, 15, 17, 0.1); }
html.is-light .nav__links { color: rgba(14, 15, 17, 0.64); }
html.is-light .nav__links a:hover { color: var(--ink); }
html.is-light .nav .btn--light { background: var(--ink); color: var(--cream); }
html.is-light .nav .btn--light:hover { background: #2B2E33; }
/* A copper line along the bottom of the nav fills as you go down the page, brightest at its leading edge */
.nav__progress { position: absolute; left: 0; right: 0; bottom: 0; height: 2px; overflow: hidden; pointer-events: none;
  opacity: 0; transition: opacity 0.45s var(--ease); }
.nav.is-solid .nav__progress { opacity: 1; }
.nav__progress i { position: absolute; inset: 0; transform: translate3d(-100%, 0, 0);
  background: linear-gradient(90deg, rgba(192, 122, 74, 0.15), var(--copper) 70%, #F6C29A); }
/* The link for the part on screen lights up, with a copper marker that slides between links */
.nav__links { position: relative; }
.nav__links a[aria-current] { color: var(--on-1); }
html.is-light .nav__links a[aria-current] { color: var(--ink); }
.nav__here { position: absolute; left: 0; bottom: -10px; width: 16px; height: 2px; border-radius: 2px; background: var(--copper);
  opacity: 0; pointer-events: none; transition: transform 0.6s var(--ease), opacity 0.4s var(--ease); }
.nav__here.is-on { opacity: 1; }

/* Hero */
.hero { position: relative; height: 160vh; height: 160svh; background: var(--ink); }
.hero__stage { position: sticky; top: 0; height: 100vh; height: 100svh; min-height: 600px; overflow: hidden; isolation: isolate; }
.hero__media { position: absolute; inset: 0; z-index: -2; background: var(--ink); }
.hero__img, .hero__gl { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero__img { object-fit: cover; object-position: 64% 58%; }
.js .hero__img { opacity: 0; animation: hero-fallback 1.2s var(--ease) 3.2s forwards; }
.no-gl .hero__img { animation-delay: 0.2s; }
.gl .hero__img { visibility: hidden; animation: none; }
@keyframes hero-fallback { to { opacity: 1; } }

.hero__shade { position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background:
    linear-gradient(to bottom, rgba(14, 15, 17, 0.72) 0%, rgba(14, 15, 17, 0.22) 24%, rgba(14, 15, 17, 0) 40%, rgba(14, 15, 17, 0) 54%, rgba(14, 15, 17, 0.55) 76%, rgba(14, 15, 17, 0.92) 100%),
    linear-gradient(to right, rgba(14, 15, 17, 0.6) 0%, rgba(14, 15, 17, 0.2) 34%, rgba(14, 15, 17, 0) 52%); }

.hero__inner { position: absolute; inset: 0;
  display: flex; flex-direction: column; justify-content: space-between;
  padding-top: calc(var(--nav-h) + clamp(28px, 6vh, 72px));
  padding-bottom: clamp(22px, 4vh, 40px); }
.hero__top, .hero__bottom { will-change: transform, opacity; }

.hero__top { display: grid; grid-template-columns: auto minmax(0, 1fr); column-gap: clamp(28px, 3.4vw, 44px); align-items: center; }
.hero__head { grid-column: 2; grid-row: 1; }
.hero__status { display: inline-flex; align-items: center; gap: 10px;
  font-size: 14.5px; line-height: 1.35; font-weight: 500; letter-spacing: -0.008em; color: var(--on-2); }
.hero__status i { width: 7px; height: 7px; border-radius: 50%; background: var(--copper); flex: none;
  animation: avail 2.6s var(--ease) infinite; }
@keyframes avail { 0% { box-shadow: 0 0 0 0 rgba(192, 122, 74, 0.55); } 70%, 100% { box-shadow: 0 0 0 9px rgba(192, 122, 74, 0); } }

.hero__title { margin-top: 18px;
  font-size: clamp(2.45rem, 4.75vw, 4.6rem); line-height: 1.03; font-weight: 600;
  letter-spacing: -0.038em; }
.hero__title .ln { display: block; text-wrap: balance; }
/* The name in copper, with a little air between it and the line about the work */
.hero__title .ln:first-child { margin-bottom: 0.2em; }
.hero__title .dim { line-height: 1.07; }
.ln__fill { background: linear-gradient(180deg, #F6BE92 0%, #E99D66 52%, #D2834F 104%);
  -webkit-background-clip: text; background-clip: text; color: transparent; }

/* Portrait, round, to the left of the name: the ring draws itself in copper with the campus, then the photo develops */
.hero__me { grid-column: 1; grid-row: 1; width: clamp(180px, min(16vw, 30vh), 232px); }
.hero__me-photo { position: relative; aspect-ratio: 1; border-radius: 50%; overflow: hidden;
  background: var(--ink-2); box-shadow: 0 34px 70px -28px rgba(0, 0, 0, 0.75); }
.hero__me-photo img { width: 100%; height: 100%; object-fit: cover; }
.hero__me-frame { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; }
.hero__me-frame circle { fill: none; stroke: rgba(239, 235, 228, 0.26); stroke-width: 3.2;
  transform: rotate(-90deg); transform-origin: 50% 50%; }
.js .hero__me-photo img { opacity: 0; filter: blur(10px) saturate(0.3); transform: scale(1.08); }
.js .hero__me-frame circle { stroke: var(--copper-hi); stroke-dasharray: 1 2; stroke-dashoffset: 1; }
.js .hero__me-frame { filter: drop-shadow(0 0 5px rgba(227, 154, 102, 0.7)); }
.hero.is-in .hero__me-photo img { opacity: 1; filter: blur(0) saturate(1); transform: none;
  transition: opacity 1s var(--ease) 0.8s, filter 1.2s var(--ease) 0.8s, transform 1.6s var(--ease) 0.8s; }
.hero.is-in .hero__me-frame circle { stroke-dashoffset: 0; stroke: rgba(239, 235, 228, 0.26);
  transition: stroke-dashoffset 1.4s cubic-bezier(0.45, 0.05, 0.2, 1) 0.2s, stroke 1s ease 1.5s; }
.hero.is-in .hero__me-frame { filter: drop-shadow(0 0 0 rgba(227, 154, 102, 0)); transition: filter 1s ease 1.5s; }
.hero__me-cap { display: flex; flex-direction: column; align-items: center; margin-top: 14px; line-height: 1.3;
  text-shadow: 0 1px 14px rgba(14, 15, 17, 0.95), 0 0 4px rgba(14, 15, 17, 0.8); }
.hero__me-role { font-size: 13.5px; font-weight: 500; color: var(--on-2); }

.hero__sub { max-width: 31em; font-size: clamp(16px, 1.3vw, 19px); line-height: 1.5; color: var(--on-2); }
.hero__actions { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 26px; }

/* The four numbers recruiters look for, kept large */
.hero__stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-top: clamp(26px, 4.5vh, 46px); padding-top: clamp(16px, 2.6vh, 24px);
  border-top: 1px solid rgba(239, 235, 228, 0.16); }
.hero__stats li { min-width: 0; padding-right: 16px; }
.hero__stats li + li { padding-left: clamp(16px, 2vw, 28px); border-left: 1px solid rgba(239, 235, 228, 0.1); }
.stat__num { display: block; font-size: clamp(30px, 3.3vw, 50px); line-height: 1; font-weight: 600;
  letter-spacing: -0.04em; color: var(--cream); font-variant-numeric: tabular-nums; white-space: nowrap; }
.stat__label { display: block; margin-top: 10px; max-width: 18em;
  font-size: clamp(13px, 1vw, 14.5px); line-height: 1.35; font-weight: 500; color: var(--on-2); }

/* Odometer digits for the counted stats */
.odo { display: inline-flex; align-items: flex-start; }
.odo__c, .odo__d { display: inline-block; height: 1em; line-height: 1; }
.odo__c { white-space: pre; }
.odo__d { overflow: hidden; }
.odo__col { display: block; transition: transform 1.6s cubic-bezier(0.16, 0.84, 0.22, 1) var(--od, 0s); }
.odo__col > span { display: block; height: 1em; }
.is-in .odo__col { transform: translate3d(0, calc(var(--n) * -1em), 0); }

/* Intro reveal: soft focus pull, then settle */
.js .rv-in { opacity: 0; transform: translate3d(0, 0.45em, 0); filter: blur(12px); }
.hero.is-in .rv-in { opacity: 1; transform: none; filter: blur(0);
  transition: opacity 0.85s var(--ease), transform 1.05s var(--ease), filter 0.9s var(--ease);
  transition-delay: var(--d, 0s); }
.hero__stats.rv-in { transform: translate3d(0, 14px, 0); }

/* Statement */
/* Rises over the last part of the hero while the scene settles into ink */
.statement { position: relative; z-index: 1; margin-top: -32vh; margin-top: -32svh;
  padding: 0 0 clamp(120px, 20vh, 200px); }
.statement__text { margin-top: 26px; max-width: 19em;
  font-size: clamp(30px, 3.9vw, 56px); line-height: 1.12; font-weight: 600; letter-spacing: -0.032em; }
.statement__text .w { opacity: 0.16; }
.statement__by { margin-top: 40px; font-size: 15px; font-weight: 500; color: var(--on-3); }

/* Intro video */
.film { position: relative; }
.film__stage { position: relative; padding-bottom: clamp(90px, 14vh, 160px); }
.film__head { text-align: center; }
.film__head .display { margin: 20px auto 0; max-width: 12em; }
.film__frame { margin-top: clamp(36px, 6vh, 64px); }
.film__card { position: relative; overflow: hidden; aspect-ratio: 16 / 9; border-radius: 22px;
  background: var(--ink-2); isolation: isolate; }
.film__media { position: absolute; inset: 0; transform-origin: 50% 50%; }
.film__poster, .film__video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 60% 50%; }
.film__video { opacity: 0; background: #000; transition: opacity 0.6s var(--ease); }
.film.has-frame .film__video { opacity: 1; }

.film__ui { position: absolute; inset: 0; z-index: 2; }
.film__shade { position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(to top, rgba(14, 15, 17, 0.62) 0%, rgba(14, 15, 17, 0) 40%);
  transition: opacity 0.6s var(--ease); }
.film__play { position: absolute; left: clamp(16px, 2.2vw, 30px); bottom: clamp(16px, 2.2vw, 30px);
  display: inline-flex; align-items: center; gap: 12px; height: 56px; padding: 0 22px 0 8px; border-radius: 999px;
  background: var(--cream); color: var(--ink); white-space: nowrap;
  font-size: 16px; line-height: 1; font-weight: 500; letter-spacing: -0.014em;
  box-shadow: 0 18px 44px -18px rgba(0, 0, 0, 0.55);
  transition: transform 0.5s var(--ease), opacity 0.4s var(--ease), background-color 0.3s var(--ease); }
.film__play-icon { width: 40px; height: 40px; display: grid; place-items: center; border-radius: 50%; background: var(--ink); color: var(--cream); }
.film__play-icon svg { margin-left: 2px; }
.film__play-time { color: rgba(14, 15, 17, 0.5); font-variant-numeric: tabular-nums; }
.film__play::before { content: ""; position: absolute; inset: 0; border-radius: inherit; animation: ring 2.8s var(--ease) infinite; }
.film__play:hover { background: #fff; transform: scale(1.03); }
@keyframes ring { 0% { box-shadow: 0 0 0 0 rgba(227, 154, 102, 0.5); } 70%, 100% { box-shadow: 0 0 0 16px rgba(227, 154, 102, 0); } }

.film__controls { position: absolute; left: clamp(14px, 2vw, 24px); bottom: clamp(16px, 2vw, 26px);
  display: flex; align-items: center; gap: 8px;
  opacity: 0; visibility: hidden; transition: opacity 0.4s var(--ease), visibility 0.4s; }
.film__btn { width: 40px; height: 40px; display: grid; place-items: center; border-radius: 50%;
  background: rgba(14, 15, 17, 0.45); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
  box-shadow: inset 0 0 0 1px rgba(239, 235, 228, 0.22); transition: background-color 0.3s var(--ease); }
.film__btn:hover { background: rgba(14, 15, 17, 0.7); }
.film__time { margin-left: 6px; font-size: 13px; font-weight: 500; font-variant-numeric: tabular-nums;
  text-shadow: 0 1px 10px rgba(0, 0, 0, 0.45); }
.film__bar { position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: rgba(239, 235, 228, 0.16);
  opacity: 0; transition: opacity 0.4s var(--ease); }
.film__bar i { display: block; height: 100%; background: var(--copper); transform-origin: 0 50%; transform: scaleX(0); }

/* Once started, the small controls take over; the big button comes back only to watch again */
.film.is-started .film__controls { opacity: 1; visibility: visible; }
.film.is-started .film__bar { opacity: 1; }
.film.is-started .film__play { opacity: 0; visibility: hidden; transform: scale(0.94); }
.film.is-ended .film__play { opacity: 1; visibility: visible; transform: none; }
.film.is-ended .film__controls { opacity: 0; visibility: hidden; }
.film.is-playing.is-idle .film__controls, .film.is-playing.is-idle .film__shade { opacity: 0; }
.film.is-playing.is-idle { cursor: none; }
.film__toggle .i-play, .film__mute .i-muted { display: none; }
.film:not(.is-playing) .film__toggle .i-play { display: block; }
.film:not(.is-playing) .film__toggle .i-pause { display: none; }
.film.is-muted .film__mute .i-muted { display: block; }
.film.is-muted .film__mute .i-sound { display: none; }

/* Wide screens: the card is a window that opens to the full screen as you scroll */
.film--grow .film__track { height: 180vh; height: 180svh; }
.film--grow .film__stage { position: sticky; top: 0; height: 100vh; height: 100svh; padding: 0; overflow: hidden; }
.film--grow .film__head { position: absolute; left: 0; right: 0; top: calc(var(--nav-h) + clamp(12px, 4vh, 48px)); }
.film--grow .film__frame { position: absolute; inset: 0; max-width: none; margin: 0; padding: 0; }
.film--grow .film__card { position: absolute; inset: 0; aspect-ratio: auto; border-radius: 0; background: transparent;
  -webkit-clip-path: inset(var(--t, 0px) var(--r, 0px) var(--b, 0px) var(--l, 0px) round var(--rad, 0px));
  clip-path: inset(var(--t, 0px) var(--r, 0px) var(--b, 0px) var(--l, 0px) round var(--rad, 0px)); }
.film--grow .film__ui { inset: var(--t, 0px) var(--r, 0px) var(--b, 0px) var(--l, 0px); }
.film--grow .film__media { will-change: transform; }

/* Worked with */
.worked { padding: clamp(90px, 14vh, 150px) 0 clamp(70px, 10vh, 120px); overflow: hidden; }
.marquee { margin-top: clamp(22px, 3vh, 32px); }
.marquee__track { display: flex; }
.marquee__list { display: flex; flex-wrap: wrap; row-gap: 6px; padding: 0 var(--edge); }
.marquee__list li { display: inline-flex; align-items: center; white-space: nowrap;
  font-size: clamp(28px, 4.2vw, 64px); line-height: 1.15; font-weight: 600; letter-spacing: -0.035em;
  color: rgba(239, 235, 228, 0.3); transition: color 0.5s var(--ease); }
.marquee__list li::after { content: ""; flex: none; width: 0.15em; height: 0.15em; margin: 0 0.55em; border-radius: 2px; background: var(--copper); }
.marquee__list li:last-child::after { display: none; }
.marquee__list li:hover { color: var(--cream); }
.marquee.is-moving { -webkit-mask-image: linear-gradient(90deg, transparent, #000 7%, #000 93%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 7%, #000 93%, transparent); }
.marquee.is-moving .marquee__track { width: max-content; will-change: transform; }
.marquee.is-moving .marquee__list { flex-wrap: nowrap; padding: 0; }
.marquee.is-moving .marquee__list li:last-child::after { display: block; }

/* Galleries: every photo for a role or project. They change by themselves while in view,
   and the photos button opens them full screen. */
.gal { position: relative; }
.gal__frame { position: relative; overflow: hidden; aspect-ratio: 3 / 2; border-radius: 16px;
  background: var(--ink-3); isolation: isolate; touch-action: pan-y; -webkit-user-select: none; user-select: none; }
.gal__pan { position: absolute; inset: 0; }
.gal__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; -webkit-user-drag: none; }

/* Without JS the photos sit side by side and scroll */
html:not(.js) .gal__pan { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; }
html:not(.js) .gal__img { position: relative; flex: 0 0 100%; scroll-snap-align: start; }

/* With JS they stack and cross fade, each one settling in with a slow zoom.
   Photos after the first wait to load until their gallery is close. */
.js .gal__img { opacity: 0; transform: scale(1.04); }
.js .gal:not(.is-primed) .gal__img:not(.is-on) { display: none; }
.js .gal__img.is-prev { opacity: 1; transform: none; z-index: 1; }
.js .gal__img.is-on { opacity: 1; transform: none; z-index: 2;
  transition: opacity 0.45s var(--ease), transform 2s cubic-bezier(0.16, 0.7, 0.24, 1); }
.js .gal__frame { cursor: zoom-in; }

.gal__ui { position: absolute; inset: 0; z-index: 3; pointer-events: none; }
.gal__ui button { pointer-events: auto; }
.gal__shade { position: absolute; left: 0; right: 0; bottom: 0; height: 38%;
  background: linear-gradient(to top, rgba(14, 15, 17, 0.6), rgba(14, 15, 17, 0)); }
.gal__glass { background: rgba(14, 15, 17, 0.42); color: var(--cream);
  -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
  box-shadow: inset 0 0 0 1px rgba(239, 235, 228, 0.22); transition: background-color 0.3s var(--ease), opacity 0.3s var(--ease); }
.gal__glass:hover { background: rgba(14, 15, 17, 0.66); }
.gal__row { position: absolute; left: 12px; bottom: 12px; display: flex; align-items: center; gap: 10px; }
.gal__toggle { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 50%; }
.gal__toggle .i-play { display: none; }
.gal.is-stopped .gal__toggle .i-play { display: block; }
.gal.is-stopped .gal__toggle .i-pause { display: none; }
.gal.is-static .gal__toggle { display: none; }
.gal__bars { display: flex; gap: 5px; }
.gal__bar { position: relative; width: 24px; height: 26px; }
.gal__bar::before, .gal__bar i { content: ""; position: absolute; left: 0; right: 0; top: 50%; height: 3px; margin-top: -1.5px; border-radius: 2px; }
.gal__bar::before { background: rgba(239, 235, 228, 0.32); box-shadow: 0 1px 6px rgba(0, 0, 0, 0.25); }
.gal__bar i { display: block; background: var(--cream); transform-origin: 0 50%; transform: scaleX(0); }
.gal__bar.is-done i { transform: scaleX(1); }
.gal__bar.is-on i { animation: gal-fill var(--gal-t, 1.25s) linear forwards; animation-play-state: paused; }
.gal.is-running .gal__bar.is-on i { animation-play-state: running; }
.gal.is-static .gal__bar.is-on i { animation: none; transform: scaleX(1); }
@keyframes gal-fill { from { transform: scaleX(0); } to { transform: scaleX(1); } }
.gal__all { position: absolute; right: 12px; bottom: 12px; display: inline-flex; align-items: center; gap: 8px;
  height: 34px; padding: 0 14px 0 11px; border-radius: 999px;
  font-size: 13.5px; line-height: 1; font-weight: 500; letter-spacing: -0.01em; white-space: nowrap; }

.gal__nav { position: absolute; top: 50%; width: 42px; height: 42px; margin-top: -21px; display: grid; place-items: center; border-radius: 50%; opacity: 0; }
.gal__prev { left: 12px; }
.gal__next { right: 12px; }
.gal:hover .gal__nav, .gal__nav:focus-visible { opacity: 1; }
@media (hover: none) { .gal__nav { display: none; } }

/* Full screen photo viewer */
.viewer { position: fixed; inset: 0; width: 100vw; height: 100%; max-width: none; max-height: none; margin: 0; padding: 0; border: 0;
  background: rgba(10, 11, 12, 0.97); color: var(--cream); overflow: hidden;
  opacity: 0; transition: opacity 0.35s var(--ease); }
.viewer::backdrop { background: transparent; }
.viewer[open] { display: grid; grid-template-rows: auto minmax(0, 1fr) auto; }
.viewer.is-open { opacity: 1; }
.viewer__top { display: flex; align-items: center; gap: 20px; padding: 14px var(--gutter); }
.viewer__cap { flex: 1; min-width: 0; line-height: 1.3; }
.viewer__cap b { display: block; font-size: 16px; font-weight: 600; letter-spacing: -0.02em; }
.viewer__cap span { display: block; margin-top: 2px; font-size: 13.5px; color: var(--on-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.viewer__count { font-size: 14px; font-weight: 500; color: var(--on-2); font-variant-numeric: tabular-nums; }
.viewer__close, .viewer__nav { width: 44px; height: 44px; display: grid; place-items: center; border-radius: 50%; flex: none; }
.viewer__stage { position: relative; display: grid; place-items: center; min-height: 0; padding: 0 clamp(12px, 7vw, 112px); touch-action: pan-y; }
.viewer__img { max-width: 100%; max-height: 100%; width: auto; height: auto; border-radius: 10px;
  transition: opacity 0.22s ease, transform 0.45s var(--ease); -webkit-user-drag: none; }
.viewer__img.is-out { opacity: 0; transform: scale(0.985); }
.viewer:not(.is-open) .viewer__img { transform: scale(0.96); }
.viewer__nav { position: absolute; top: 50%; margin-top: -22px; }
.viewer__prev { left: clamp(10px, 2vw, 32px); }
.viewer__next { right: clamp(10px, 2vw, 32px); }
.viewer__thumbs { position: relative; display: flex; gap: 8px; padding: 14px var(--gutter) max(18px, env(safe-area-inset-bottom)); overflow-x: auto; scrollbar-width: none; }
.viewer__thumbs > :first-child { margin-left: auto; }
.viewer__thumbs > :last-child { margin-right: auto; }
.viewer__thumb { flex: none; width: 76px; aspect-ratio: 3 / 2; border-radius: 8px; overflow: hidden; opacity: 0.42;
  box-shadow: inset 0 0 0 1px rgba(239, 235, 228, 0.16); transition: opacity 0.3s var(--ease), box-shadow 0.3s var(--ease); }
.viewer__thumb img { width: 100%; height: 100%; object-fit: cover; }
.viewer__thumb:hover { opacity: 0.8; }
.viewer__thumb[aria-current="true"] { opacity: 1; box-shadow: 0 0 0 2px var(--copper); }

/* Experience */
.work { position: relative; padding: clamp(40px, 6vh, 80px) 0 clamp(110px, 16vh, 180px); background: var(--ink); }
.work__pin { position: relative; }
/* As cards, one role per row keeps the photos as wide as the screen allows */
.work__track { display: grid; grid-template-columns: minmax(0, 1fr); gap: 20px;
  width: 100%; max-width: calc(var(--maxw) + var(--gutter) * 2); margin: 0 auto; padding: 0 var(--gutter); }
@media (min-width: 861px) { .work__track { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.work__intro { grid-column: 1 / -1; max-width: 34em; margin-bottom: 28px; }
.work__intro .display { margin-top: 20px; }
.work__lede { margin-top: 22px; max-width: 26em; font-size: clamp(16px, 1.3vw, 18px); line-height: 1.5; color: var(--on-2); }
.work__hint { display: none; align-items: center; gap: 10px; margin-top: 34px; font-size: 14px; font-weight: 500; color: var(--on-3); }
.work__hint svg { animation: nudge 1.8s var(--ease) infinite; }
@keyframes nudge { 0%, 100% { transform: none; } 50% { transform: translateX(5px); } }

/* The photos run edge to edge across the top of each card */
.job { display: flex; flex-direction: column; overflow: hidden; border-radius: 24px;
  background: var(--ink-2); box-shadow: inset 0 0 0 1px var(--line);
  transition: box-shadow 0.4s var(--ease); }
.job:hover { box-shadow: inset 0 0 0 1px rgba(239, 235, 228, 0.22); }
.job__gal { order: -1; }
.job__gal .gal__frame { border-radius: 0; }
.job__body { display: flex; flex: 1; flex-direction: column; padding: clamp(20px, 3vw, 28px) clamp(18px, 3vw, 28px) clamp(18px, 2.6vw, 24px); }
.job__meta { display: flex; align-items: center; gap: 12px; font-size: 13px; font-weight: 500; color: var(--on-3); }
.job__n { color: var(--copper-hi); font-variant-numeric: tabular-nums; }
.job__org { margin-top: 12px; font-size: clamp(24px, 2vw, 30px); line-height: 1.1; font-weight: 600; letter-spacing: -0.03em; }
.job__role { margin-top: 6px; font-size: 15px; line-height: 1.35; font-weight: 500; color: var(--on-2); }
.job__text { max-width: 40em; margin: 14px 0 22px; font-size: 15px; line-height: 1.55; color: var(--on-2); }
.job__stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px;
  margin-top: auto; padding-top: 16px; border-top: 1px solid var(--line); }
.job__stats strong { display: block; font-size: 22px; line-height: 1.1; font-weight: 600; letter-spacing: -0.03em; white-space: nowrap; }
.job__stats span { display: block; margin-top: 5px; font-size: 12.5px; line-height: 1.35; font-weight: 500; color: var(--on-3); }

.work__end { display: flex; flex-direction: column; align-items: flex-start; justify-content: center; gap: 22px;
  padding: 32px 28px; border-radius: 24px; box-shadow: inset 0 0 0 1px var(--line); }
.work__end-text { max-width: 14em; font-size: 22px; line-height: 1.25; font-weight: 600; letter-spacing: -0.025em; }

.work__progress { display: none; }

/* Wide screens: the section pins and each role takes the screen in turn. The photo gets all the room
   the story leaves: as wide as the screen allows, or as tall, whichever runs out first. */
.work--rail { padding: 0;
  --txt: clamp(270px, 21vw, 340px);
  --col-gap: clamp(28px, 2.8vw, 48px);
  --panel: calc(100vw - clamp(20px, 2.5vw, 40px) * 2);
  --gal-w: min(calc((100vh - var(--nav-h) - 128px) * 1.5), calc(var(--panel) - var(--txt) - var(--col-gap))); }
@supports (height: 100svh) {
  .work--rail { --gal-w: min(calc((100svh - var(--nav-h) - 128px) * 1.5), calc(var(--panel) - var(--txt) - var(--col-gap))); }
}
.work--rail .work__pin { display: flex; flex-direction: column; justify-content: center;
  height: 100vh; height: 100svh; padding: var(--nav-h) 0 clamp(44px, 8vh, 72px); overflow: hidden; }
.work--rail .work__track { display: flex; align-items: center; gap: clamp(48px, 5vw, 96px);
  width: max-content; max-width: none; margin: 0; padding: 0 var(--edge); will-change: transform; }
.work--rail .work__intro { flex: none; width: var(--txt); margin: 0; }
.work--rail .work__hint { display: inline-flex; }
.work--rail .job { flex: none; flex-direction: row; align-items: center; gap: var(--col-gap);
  overflow: visible; border-radius: 0; background: none; box-shadow: none; }
.work--rail .job__body { flex: none; width: var(--txt); padding: 0; }
.work--rail .job__gal { order: 0; flex: none; width: var(--gal-w); }
.work--rail .job__gal .gal__frame { border-radius: 20px; box-shadow: 0 44px 90px -44px rgba(0, 0, 0, 0.85); }
.work--rail .gal__pan { left: -3%; right: -3%; }
.work--rail .job__org { margin-top: 14px; font-size: clamp(28px, 2.4vw, 38px); }
.work--rail .job__role { font-size: 16px; }
.work--rail .job__text { margin: 18px 0 26px; font-size: 16px; }
.work--rail .work__end { flex: none; width: clamp(260px, 22vw, 320px); }
.work--rail .work__progress { position: absolute; left: 0; right: 0; bottom: clamp(18px, 3.5vh, 32px);
  display: flex; align-items: center; gap: 18px; font-size: 13px; font-weight: 500; color: var(--on-3); }
.work__count { font-variant-numeric: tabular-nums; }
.work__count b { font-weight: 600; color: var(--on-1); }
.work__line { position: relative; flex: 1; height: 1px; background: var(--line); }
.work__line i { position: absolute; inset: 0; background: var(--copper); transform-origin: 0 50%; transform: scaleX(0); }

/* Numbers: the digits roll into place as the band comes in */
.nums { display: flex; align-items: center; min-height: 66vh; min-height: 66svh; padding: clamp(90px, 13vh, 150px) 0; }
.nums__grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr));
  margin-top: clamp(26px, 4vh, 40px); border-top: 1px solid var(--rule); }
.nums__grid li { grid-column: span 2; min-width: 0;
  padding: clamp(24px, 3.6vh, 38px) clamp(16px, 2vw, 32px) clamp(26px, 4vh, 44px);
  border-bottom: 1px solid var(--rule); }
.nums__grid li:nth-child(n + 4) { grid-column: span 3; }
.nums__grid li:nth-child(1), .nums__grid li:nth-child(4) { padding-left: 0; }
.nums__grid li:nth-child(2), .nums__grid li:nth-child(3), .nums__grid li:nth-child(5) { border-left: 1px solid var(--rule); }
.nums__n { display: block; font-size: clamp(48px, 6.2vw, 100px); line-height: 1; font-weight: 600;
  letter-spacing: -0.045em; font-variant-numeric: tabular-nums; white-space: nowrap; }
.nums__l { display: block; margin-top: clamp(12px, 1.8vh, 18px); max-width: 22em;
  font-size: clamp(14px, 1.1vw, 16px); line-height: 1.4; font-weight: 500; color: var(--fg-2); }
.js .nums__word { opacity: 0; filter: blur(10px); transform: translate3d(0, 0.18em, 0); }
.js .nums__l { opacity: 0; transform: translate3d(0, 8px, 0); }
.nums.is-in .nums__word { opacity: 1; filter: blur(0); transform: none;
  transition: opacity 0.8s var(--ease) 0.45s, filter 0.9s var(--ease) 0.45s, transform 1s var(--ease) 0.45s; }
.nums.is-in .nums__l { opacity: 1; transform: none; transition: opacity 0.7s var(--ease) 0.3s, transform 0.8s var(--ease) 0.3s; }

/* Projects: one big card each, the photos across the top and the story underneath */
.projects { padding: clamp(100px, 15vh, 170px) 0 clamp(90px, 14vh, 160px); }
.projects__head { text-align: center; }
.projects__head .display { max-width: 15em; margin: 20px auto 0; }
.pstack { --pgap: 20px; width: 100%; max-width: calc(1360px + var(--gutter) * 2);
  margin: clamp(44px, 7vh, 72px) auto 0; padding: 0 var(--gutter); }
.pcard { margin: 0 auto; }
.pcard + .pcard { margin-top: var(--pgap); }
/* The cards stay ink on the light page */
.pcard__in { position: relative; display: flex; flex-direction: column; overflow: hidden; border-radius: 26px;
  --fg: #EFEBE4; --fg-2: rgba(239, 235, 228, 0.7); --fg-3: rgba(239, 235, 228, 0.5); --rule: rgba(239, 235, 228, 0.14);
  background: var(--ink-2); color: var(--fg); box-shadow: 0 44px 90px -48px rgba(14, 15, 17, 0.6); }
.pcard__gal .gal__frame, .pcard__paper { aspect-ratio: 2 / 1; border-radius: 0; }
/* Name and button on the left, the story and tags on the right, so the text stays two short rows */
.pcard__body { display: grid; grid-template-columns: minmax(0, 0.82fr) minmax(0, 1.18fr);
  grid-template-areas: "head text" "link chips"; align-items: start; align-content: start;
  column-gap: clamp(28px, 4vw, 64px); row-gap: 14px;
  padding: clamp(20px, 1.7vw, 26px) clamp(20px, 2.6vw, 34px) clamp(22px, 1.8vw, 28px); }
.pcard__head { grid-area: head; }
.pcard__meta { display: flex; align-items: center; gap: 12px; font-size: 13px; line-height: 1.3; font-weight: 500; color: var(--fg-3); }
.pcard__n { display: inline-flex; align-items: center; gap: 12px; font-weight: 600; color: var(--copper-hi); font-variant-numeric: tabular-nums; }
.pcard__n::after { content: ""; width: 18px; height: 1px; background: var(--rule); }
.pcard__name { margin-top: 10px; font-size: clamp(28px, 2.4vw, 36px); line-height: 1.04; font-weight: 600; letter-spacing: -0.035em; }
.pcard__kind { margin-top: 8px; font-size: 15.5px; line-height: 1.4; color: var(--fg-2); }
.pcard__text { grid-area: text; max-width: 44em; font-size: 15px; line-height: 1.55; color: var(--fg-2); }
.pcard__chips { grid-area: chips; align-self: center; display: flex; flex-wrap: wrap; gap: 6px; }
.pcard__chips li { padding: 6px 12px; border-radius: 999px; font-size: 12.5px; line-height: 1.2; font-weight: 500; color: var(--fg-2);
  box-shadow: inset 0 0 0 1px var(--rule); }
.pcard__link { grid-area: link; justify-self: start; align-self: center; height: 42px; padding: 0 18px; font-size: 15px; }
/* Darkens a card as the next one covers it */
.pcard__veil { position: absolute; inset: 0; z-index: 5; background: var(--ink); opacity: 0; pointer-events: none; }

/* The paper has no photos, so it gets a title page */
.pcard__paper { container-type: inline-size; }
.paper { display: flex; flex-direction: column; justify-content: space-between; gap: 18px; height: 100%;
  padding: clamp(22px, 3.6vw, 56px); padding: clamp(22px, 4.8cqi, 60px); background: var(--cream); color: var(--ink); }
.paper__meta { display: flex; align-items: center; gap: 12px; font-size: clamp(13px, 1vw, 14.5px); font-weight: 600; letter-spacing: 0.01em; color: rgba(14, 15, 17, 0.6); }
.paper__meta::before { content: ""; width: 26px; height: 3px; border-radius: 2px; background: var(--copper); }
.paper__title { max-width: 17em; font-size: clamp(22px, 3.3vw, 52px); font-size: clamp(20px, 4cqi, 52px);
  line-height: 1.08; font-weight: 600; letter-spacing: -0.035em; }
.paper__by { font-size: clamp(13px, 1.05vw, 15px); line-height: 1.4; color: rgba(14, 15, 17, 0.66); }

/* Wide screens: each card settles under the nav and the next one slides up over it */
.pstack.is-stacked { --pgap: clamp(40px, 9vh, 90px); }
.pstack.is-stacked .pcard { position: sticky; top: calc(var(--nav-h) + 12px); }
.pstack.is-stacked .pcard__in { transform-origin: 50% 0; }
.pcard__in.is-moving { will-change: transform; }

@media (min-width: 861px) {
  /* The photos take the height the text leaves, so a whole card fits under the nav */
  .pcard { width: clamp(min(100%, 760px), calc((100vh - var(--nav-h) - 24px - var(--band, 200px)) * 2), 100%); }
  @supports (height: 100svh) {
    .pcard { width: clamp(min(100%, 760px), calc((100svh - var(--nav-h) - 24px - var(--band, 200px)) * 2), 100%); }
  }
  .pcard__body { min-height: var(--band-h, 0px); }
}

/* Education: the two schools as photo tiles */
.edu { padding: clamp(40px, 6vh, 72px) 0 clamp(110px, 16vh, 180px); }
.edu__head .display { max-width: 13.5em; margin-top: 20px; }
.edu__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(20px, 2.6vw, 36px);
  margin-top: clamp(40px, 6vh, 64px); }
.school__media { position: relative; overflow: hidden; aspect-ratio: 16 / 10; border-radius: 22px;
  background: var(--ink-3); isolation: isolate; }
.school__media img { width: 100%; height: 100%; object-fit: cover; }
/* The photo develops as the tile comes in, like the portrait in the hero */
.js .school__media img { opacity: 0; filter: blur(10px) saturate(0.3); transform: scale(1.08); }
.js .school.is-in .school__media img { opacity: 1; filter: blur(0) saturate(1); transform: none;
  transition: opacity 1s var(--ease) 0.15s, filter 1.2s var(--ease) 0.15s, transform 1.6s var(--ease) 0.15s; }
@media (hover: hover) {
  .js .school.is-in:hover .school__media img { transform: scale(1.05); transition: transform 1.8s var(--ease); }
}
.school__body { padding: 22px 2px 0; }
.school__meta { font-size: 13.5px; line-height: 1.3; font-weight: 500; color: var(--fg-3); }
.school__name { margin-top: 10px; font-size: clamp(24px, 2.2vw, 32px); line-height: 1.1; font-weight: 600; letter-spacing: -0.03em; }
.school__deg { margin-top: 8px; font-size: 16px; line-height: 1.4; color: var(--fg-2); }
.school__facts { margin-top: 22px; }
.school__facts div { display: grid; grid-template-columns: 8.5em minmax(0, 1fr); gap: 16px; padding: 12px 0;
  border-top: 1px solid var(--rule); font-size: 15px; line-height: 1.4; }
.school__facts dt { font-weight: 500; color: var(--fg-3); }
.school__facts dd { font-weight: 500; }
.medal { display: inline-block; width: 9px; height: 9px; margin-right: 10px; border-radius: 50%; vertical-align: 1px;
  background: var(--copper); box-shadow: 0 0 0 3px rgba(192, 122, 74, 0.22); }

/* Credentials: four short lists instead of a cloud of tags */
.creds { margin-top: clamp(90px, 13vh, 140px); }
.creds__title { max-width: 24em; font-size: clamp(26px, 2.4vw, 36px); line-height: 1.12; font-weight: 600; letter-spacing: -0.03em; }
.creds__grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 40px clamp(20px, 2.4vw, 36px);
  margin-top: clamp(28px, 4vh, 44px); }
.creds__group { position: relative; padding-top: 18px; border-top: 1px solid var(--rule); }
.creds__group::before { content: ""; position: absolute; left: 0; top: -1px; width: 28px; height: 2px; background: var(--copper); }
.creds__name { font-size: 15px; line-height: 1.3; font-weight: 600; letter-spacing: -0.008em; color: var(--fg-3); }
.creds__list { margin-top: 12px; }
.creds__list li { padding: 6px 0; font-size: clamp(16px, 1.25vw, 18px); line-height: 1.35; font-weight: 500; letter-spacing: -0.015em; }

/* Contact: the page is ink again for the close */
.contact { padding: clamp(110px, 17vh, 190px) 0 clamp(80px, 12vh, 130px); }
.contact__title { margin-top: 12px; font-size: clamp(4.2rem, 19vw, 15rem); line-height: 0.92; font-weight: 600;
  letter-spacing: -0.055em; white-space: nowrap; }
.contact__title .ch { display: inline-block; transform-origin: 50% 85%; }
.contact__grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: clamp(32px, 5vw, 88px);
  align-items: start; margin-top: clamp(40px, 6vh, 72px); }
.contact__lede { max-width: 30em; font-size: clamp(17px, 1.4vw, 20px); line-height: 1.5; color: var(--fg-2); }
.contact__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.contact__list { margin-top: 40px; border-bottom: 1px solid var(--rule); }
.contact__list div { display: grid; grid-template-columns: 7em minmax(0, 1fr); gap: 16px; align-items: center;
  min-height: 52px; padding: 10px 0; border-top: 1px solid var(--rule); font-size: 15.5px; line-height: 1.35; }
.contact__list dt { font-weight: 500; color: var(--fg-3); }
.contact__list dd { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-width: 0; font-weight: 500; }
.contact__list a { transition: color 0.3s var(--ease); }
.contact__list a:hover { color: var(--copper-hi); }
.contact__copy { flex: none; height: 30px; padding: 0 12px; border-radius: 999px; font-size: 13px; font-weight: 500; color: var(--fg-2);
  box-shadow: inset 0 0 0 1px var(--rule); transition: color 0.3s var(--ease), box-shadow 0.3s var(--ease); }
.contact__copy:hover { color: var(--fg); box-shadow: inset 0 0 0 1px var(--fg-3); }

/* The message form stays an ink card */
.cform { position: relative; padding: clamp(22px, 2.6vw, 36px); border-radius: 24px;
  background: var(--ink-2); color: var(--cream);
  box-shadow: inset 0 0 0 1px rgba(239, 235, 228, 0.08), 0 40px 80px -50px rgba(0, 0, 0, 0.6); }
.cform__title { font-size: 22px; line-height: 1.2; font-weight: 600; letter-spacing: -0.025em; }
.cform__note { margin-top: 4px; font-size: 14.5px; color: var(--on-3); }
.cform__row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.field { display: block; margin-top: 18px; }
.field__label { display: block; margin-bottom: 8px; font-size: 13.5px; line-height: 1.3; font-weight: 500; color: var(--on-2); }
.field input, .field textarea { display: block; width: 100%; padding: 13px 16px; border: 0; border-radius: 14px;
  background: rgba(239, 235, 228, 0.05); box-shadow: inset 0 0 0 1px rgba(239, 235, 228, 0.14);
  color: var(--cream); font: inherit; font-size: 16px; line-height: 1.4;
  transition: box-shadow 0.3s var(--ease), background-color 0.3s var(--ease); }
.field textarea { min-height: 140px; resize: vertical; }
.field ::placeholder { color: rgba(239, 235, 228, 0.34); }
.field input:hover, .field textarea:hover { box-shadow: inset 0 0 0 1px rgba(239, 235, 228, 0.26); }
.field input:focus, .field textarea:focus { outline: none; background: rgba(239, 235, 228, 0.08);
  box-shadow: inset 0 0 0 1px var(--copper), 0 0 0 4px rgba(192, 122, 74, 0.2); }
.field input:-webkit-autofill { -webkit-text-fill-color: var(--cream); caret-color: var(--cream);
  box-shadow: inset 0 0 0 1px rgba(239, 235, 228, 0.14), inset 0 0 0 100px #24272B; }
.cform.was-tried :invalid { box-shadow: inset 0 0 0 1px rgba(227, 154, 102, 0.9); }
.cform__trap { display: none; }
.cform__foot { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 18px; margin-top: 24px; }
.cform__send[disabled] { opacity: 0.6; cursor: progress; }
.cform__status { font-size: 14.5px; line-height: 1.45; color: var(--on-2); }
.cform__status a { color: var(--cream); text-decoration: underline; text-underline-offset: 3px; }
.cform__done { display: none; flex-direction: column; align-items: flex-start; justify-content: center; gap: 8px; outline: none; }
/* Once sent, the thank you note takes the form's place at the same height */
.cform.is-sent { display: flex; flex-direction: column; justify-content: center; }
.cform.is-sent > :not(.cform__done) { display: none; }
.cform.is-sent .cform__done { display: flex; }
.cform__tick { width: 44px; height: 44px; display: grid; place-items: center; margin-bottom: 10px; border-radius: 50%;
  color: var(--copper-hi); box-shadow: inset 0 0 0 1px rgba(227, 154, 102, 0.5); }
.cform__done-title { font-size: 26px; line-height: 1.15; font-weight: 600; letter-spacing: -0.03em; }
.cform__done-text { font-size: 15.5px; color: var(--on-2); }
.cform__again { margin-top: 14px; font-size: 14.5px; font-weight: 500; color: var(--on-2);
  text-decoration: underline; text-underline-offset: 3px; transition: color 0.3s var(--ease); }
.cform__again:hover { color: var(--cream); }

/* Footer: laid out like the title block on a drawing sheet */
.foot { padding: 0 0 clamp(22px, 4vh, 40px); }
.tblock { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 1px; overflow: hidden;
  border: 1px solid var(--rule); border-radius: 18px; background: var(--rule); }
.tblock__cell { grid-column: span 3; display: flex; flex-direction: column; justify-content: space-between; gap: 18px;
  min-width: 0; padding: 18px 22px 20px; background: var(--bg); }
.tblock__id { grid-column: span 6; grid-row: span 2; }
.tblock__name { font-size: clamp(22px, 2vw, 28px); line-height: 1.1; font-weight: 600; letter-spacing: -0.03em; }
.tblock__tag { max-width: 32em; font-size: 15px; line-height: 1.45; color: var(--fg-2); }
.tblock__k { font-size: 11px; line-height: 1.2; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: var(--fg-3); }
.tblock__v { font-size: 15px; line-height: 1.35; font-weight: 500; overflow-wrap: anywhere; transition: color 0.3s var(--ease); }
a.tblock__v:hover { color: var(--copper-hi); }
.tblock__top { transition: background-color 0.3s var(--ease); }
.tblock__top:hover { background: var(--ink-2); }
.tblock__arrow { transition: transform 0.4s var(--ease); }
.tblock__top:hover .tblock__arrow { transform: translateY(-3px); }
.tblock__strip { flex-direction: row; align-items: center; padding: 12px 22px; font-size: 13px; line-height: 1.3; color: var(--fg-3); }
.tblock__strip--wide { grid-column: span 6; }

/* Short laptop screens */
@media (min-width: 861px) and (max-height: 780px) {
  .hero__title { font-size: clamp(2.3rem, min(4.75vw, 8.4vh), 4.6rem); }
  .hero__sub { max-width: 36em; font-size: 16px; }
  .hero__actions { margin-top: 20px; }
  .hero__actions .btn { height: 44px; }
  .work--rail .job__org { font-size: clamp(26px, 2.2vw, 34px); }
  .work--rail .job__text { margin: 14px 0 20px; font-size: 14.5px; }
}

@media (max-width: 860px) {
  .nav__links { display: none; }
  /* The photo leads, large, with the school and availability beside it; the name runs full width below */
  .hero__top { grid-template-columns: auto minmax(0, 1fr); grid-template-rows: 1fr auto auto auto; column-gap: 18px;
    align-items: end; grid-template-areas: "photo ." "photo cap" "photo status" "title title"; }
  .hero__me, .hero__head { display: contents; }
  .hero__me-photo { grid-area: photo; width: clamp(112px, 34vw, 168px); }
  .hero__me-cap { grid-area: cap; align-items: flex-start; margin: 0 0 8px; }
  .hero__status { grid-area: status; display: flex; padding-bottom: 4px; }
  .hero__title { grid-area: title; margin-top: 18px; font-size: clamp(2.45rem, 6.4vw, 3.4rem); }

  .nums__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .nums__grid li, .nums__grid li:nth-child(n + 4) { grid-column: span 1; }
  .nums__grid li:nth-child(5) { grid-column: 1 / -1; }
  .nums__grid li:nth-child(n) { padding-left: clamp(16px, 3vw, 28px); border-left: 0; }
  .nums__grid li:nth-child(odd) { padding-left: 0; }
  .nums__grid li:nth-child(even) { border-left: 1px solid var(--rule); }

  .pcard__in { border-radius: 22px; }
  .pcard__body { grid-template-columns: minmax(0, 1fr); grid-template-areas: "head" "text" "chips" "link"; }

  /* One school per row keeps the photos large */
  .edu__grid { grid-template-columns: minmax(0, 1fr); gap: 48px; }
  .creds__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .contact__grid { grid-template-columns: minmax(0, 1fr); }
  .tblock { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tblock__cell, .tblock__strip { grid-column: span 1; }
  .tblock__id, .tblock__strip--wide { grid-column: 1 / -1; grid-row: auto; }
  .tblock__id { gap: 10px; }
}

@media (max-width: 560px) {
  /* Small enough for the name to sit on one line */
  .hero__title { font-size: clamp(1.6rem, 8.2vw, 2.5rem); line-height: 1.05; }
  .hero__top { column-gap: 14px; }
  .hero__status { font-size: 13px; align-items: flex-start; }
  .hero__status i { margin-top: 5px; }
  .hero__sub { font-size: 15px; }
  .hero__actions { gap: 8px; margin-top: 18px; }
  .hero__actions .btn { height: 44px; padding: 0 18px; font-size: 15px; }
  .hero__stats { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 16px; margin-top: 22px; padding-top: 16px; }
  .hero__stats li:nth-child(odd) { padding-left: 0; border-left: 0; }
  .stat__num { font-size: 28px; }
  .stat__label { margin-top: 7px; font-size: 12.5px; }
  .hero__shade { background:
    linear-gradient(to bottom, rgba(14, 15, 17, 0.86) 0%, rgba(14, 15, 17, 0.76) 36%, rgba(14, 15, 17, 0.5) 46%, rgba(14, 15, 17, 0) 57%, rgba(14, 15, 17, 0.25) 64%, rgba(14, 15, 17, 0.86) 75%, rgba(14, 15, 17, 0.96) 100%); }
  /* The stone lines sit over the lit rooftops on a narrow screen, so they get a soft dark halo */
  .hero__title .dim { text-shadow: 0 1px 16px rgba(14, 15, 17, 0.75), 0 0 3px rgba(14, 15, 17, 0.5); }
  /* A taller card on phones keeps the face large; the button moves off it to the corner */
  .film__card { aspect-ratio: 4 / 5; border-radius: 16px; }
  .film__poster, .film__video { object-position: 61% 50%; }
  .film__play { left: 14px; bottom: 14px; height: 48px; padding: 0 18px 0 6px; gap: 10px; font-size: 15px; }
  .film__play-icon { width: 36px; height: 36px; }
  .job__org { font-size: 24px; }
  .gal__all { height: 32px; padding: 0 12px 0 10px; font-size: 13px; }
  .gal__toggle { width: 32px; height: 32px; }
  .gal__bar { width: 18px; }

  .nums__grid { grid-template-columns: minmax(0, 1fr); }
  .nums__grid li:nth-child(n) { grid-column: 1; padding: 20px 0 22px; border-left: 0; }
  .nums__n { font-size: clamp(40px, 12vw, 52px); }
  .nums__l { margin-top: 10px; font-size: 14px; }

  .pstack { --pgap: 16px; }
  .pcard__in { border-radius: 18px; }
  .pcard__body { row-gap: 14px; padding: 18px 18px 20px; }
  .pcard__name { font-size: 26px; }
  .pcard__kind { font-size: 15px; }
  .pcard__text { font-size: 14.5px; }
  .pcard__link { margin-top: 4px; }
  /* The title page grows with its text instead of keeping the photo shape */
  .pcard__paper { aspect-ratio: auto; }
  .paper { height: auto; gap: 26px; }

  .school__media { aspect-ratio: 4 / 3; border-radius: 18px; }
  .school__body { padding-top: 18px; }
  .school__name { font-size: 24px; }
  .school__facts div { grid-template-columns: 7.2em minmax(0, 1fr); gap: 12px; font-size: 14.5px; }
  /* On phones each list runs as one line of text, so the four groups stay short */
  .creds__grid { grid-template-columns: minmax(0, 1fr); gap: 30px; }
  .creds__list { display: flex; flex-wrap: wrap; margin-top: 10px; }
  .creds__list li { padding: 2px 0; font-size: 16px; line-height: 1.5; }
  .creds__list li:not(:last-child)::after { content: "·"; margin: 0 0.5em; color: var(--fg-3); }
  .contact__lede { font-size: 17px; }
  .contact__actions { gap: 10px; margin-top: 26px; }
  .contact__actions .btn { height: 44px; padding: 0 18px; font-size: 15px; }
  .contact__list div { grid-template-columns: minmax(0, 1fr); gap: 4px; padding: 12px 0; }
  .contact__list dt { font-size: 13px; }
  .cform { border-radius: 20px; }
  .cform__row { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .tblock__cell { padding: 16px 18px 18px; }
  .tblock__strip { padding: 11px 18px; }
  .tblock__cell:nth-child(2), .tblock__cell:nth-child(3) { grid-column: 1 / -1; }

  .viewer__nav { display: none; }
  .viewer__stage { padding: 0 10px; }
  .viewer__thumb { width: 62px; }
}

/* Most phones: the first screen keeps the name, headline, numbers and buttons, and leaves room for the campus */
@media (max-width: 560px) and (max-height: 899px) {
  .hero__sub { display: none; }
  .hero__actions { margin-top: 0; }
}
/* With the browser bars showing, most phones give the page 640 to 720px of height. Tighter spacing keeps
   the numbers on the first screen with a band of campus between the headline and the buttons. */
@media (max-width: 560px) and (max-height: 720px) {
  .hero__inner { padding-top: calc(var(--nav-h) + 10px); }
  .hero__title { margin-top: 14px; font-size: clamp(1.5rem, 7.4vw, 2.3rem); }
  .hero__stats { row-gap: 12px; margin-top: 16px; padding-top: 14px; }
  .stat__num { font-size: 24px; }
  .stat__label { margin-top: 6px; font-size: 12px; }
}
/* The smallest phones in Safari, about 550px tall */
@media (max-width: 560px) and (max-height: 620px) {
  .hero__stage { min-height: 500px; }
  .hero__me-photo { width: 26vw; }
  .hero__status { font-size: 12px; }
  .hero__title { font-size: clamp(1.4rem, 7vw, 2.1rem); }
  .hero__actions .btn { height: 40px; }
  .hero__stats { row-gap: 10px; margin-top: 12px; padding-top: 12px; }
  .stat__num { font-size: 22px; }
}

@media (prefers-reduced-motion: reduce) {
  .js .rv-in { opacity: 1; transform: none; filter: none; }
  .js .hero__img { opacity: 1; animation: none; }
  .js .nav { opacity: 1; }
  .js .hero__me-photo img { opacity: 1; filter: none; transform: none; }
  .js .hero__me-frame { filter: none; }
  .js .hero__me-frame circle { stroke: rgba(239, 235, 228, 0.26); stroke-dashoffset: 0; }
  .hero { height: 100vh; height: 100svh; }
  .statement { margin-top: 0; padding-top: clamp(120px, 20vh, 200px); }
  .statement__text .w { opacity: 1; }
  .hero__status i, .film__play::before, .work__hint svg { animation: none; }
  .js .gal__img, .js .gal__img.is-on, .js .gal__img.is-prev { transform: none; transition: opacity 0.3s ease; }
  .js .nums__word, .js .nums__l { opacity: 1; filter: none; transform: none; }
  .js [data-reveal], .js .school__media img { opacity: 1; filter: none; transform: none; }
  .viewer__img, .viewer:not(.is-open) .viewer__img { transition: opacity 0.2s ease; transform: none; }
}
