@import url('animations.css');
@import url('loading.css');
@import url('lightbox.css');
@import url('typography.css');

:root {
  --base-size: 15px;
  --viewport-height: 100vh;
  --font-sans: 'Neue Haas Grotesk', 'Neue Haas Grotesk Text Pro', 'Neue Haas Grotesk Display Pro', 'Helvetica Neue', Helvetica, Arial, sans-serif;
  --font-serif: var(--font-sans);
  --swatch-1: rgba(0, 0, 0, 0.85);
  --swatch-4: rgba(0, 0, 0, 0.4);
  --pin-pad: 1.2rem;
  --pin-bar-height: 1.75rem;
  --nav-top-height: calc(var(--pin-pad) * 2 + var(--pin-bar-height) + 1px);
  --nav-bottom-height: calc(var(--pin-pad) * 2 + var(--pin-bar-height) + 1px);
  --hero-glow-blue: rgba(0, 123, 251, .24);
  --hero-glow-green: rgba(147, 222, 123, .22);
  --hero-glow-sky: rgba(113, 176, 239, .16);
  --loader-blob-blue: rgba(0, 123, 251, .52);
  --loader-blob-green: rgba(147, 222, 123, .44);
  --loader-blob-sky: rgba(113, 176, 239, .42);
  --hero-glow-x: 50%;
  --hero-glow-y: 50%;
  --selection-bg: #93DE7B;
  --selection-ink: #000;
  --accent-green: #4EAB10;
  --link-hover: #007BFB;
  --link-hover-pink: #FF4BB7;
  --case-ink: rgb(15, 17, 17);
  --case-muted: rgb(92, 92, 80);
  --highlight-pad-block: 0.08em;
  --highlight-pad-inline: 0.18em;
  --highlight-radius: 0.14em;
  --highlight-green: #93DE7B;
  --rule-color: rgba(0, 0, 0, 0.14);
  --line: rgba(0, 0, 0, 0.15);
  /* Type scale */
  --case-body-size: var(--base-size);
  --type-ui-size: var(--base-size);
  --type-emphasis-size: var(--base-size);
  --type-body-lh: 1.5;
  --case-body-lh: var(--type-body-lh);
  --case-body-track: -0.005em;
  --type-body-weight: 400;
  --type-ui-weight: 500;
  --type-emphasis-weight: 500;
  --type-label-weight: 500;
  --type-display-weight: 500;
  --prose-gap: 0.75em;
  --type-display-size: clamp(1.75rem, 3.35vw, 2.625rem);
  --type-display-lh: 1.16;
  --type-display-track: -0.02em;
  --case-title-size: clamp(1.5rem, 2.45vw, 1.875rem);
  --case-title-weight: var(--type-emphasis-weight);
  --case-callout-head-size: clamp(1.375rem, 2.15vw, 1.75rem);
  --case-callout-subhead-size: clamp(1.0625rem, 1.4vw, 1.1875rem);
  --case-callout-head-weight: 500;
  --case-callout-subhead-weight: 400;
  --case-eyebrow-size: 0.75rem;
  --case-eyebrow-weight: 400;
  --case-eyebrow-track: 0.1em;
  --case-label-size: var(--case-callout-subhead-size);
  --case-meta-label-size: var(--case-body-size);
  --case-meta-value-size: var(--case-body-size);
  --case-meta-label-weight: var(--type-ui-weight);
  --case-meta-value-weight: var(--type-body-weight);
  --case-meta-value-lh: var(--case-body-lh);
  --case-meta-value-gap: 0.2em;
  --case-meta-row-gap: 0.4rem;
  --case-meta-block-gap: clamp(1rem, 2vh, 1.35rem);
  --case-tight-lh: 1.12;
  --case-tight-track: -0.025em;
  --case-serif-head-track: -0.015em;
  --case-serif-display-track: var(--type-display-track);
  --case-prose-max: 40rem;
  --case-callout-max: 52rem;
  --case-rule: 1px solid var(--rule-color);
  --case-rule-dashed: 1px dashed var(--rule-color);
  --case-callout-rule-pad: clamp(14px, 2.1vh, 20px);
  --case-callout-structure-gap: clamp(1.35rem, 2.5vh, 1.85rem);
  --case-callout-head-gap: clamp(1.15rem, 2.2vh, 1.65rem);
  --case-callout-intro-gap: clamp(1.15rem, 2.2vh, 1.65rem);
  --case-callout-item-gap: clamp(0.6rem, 1.1vh, 0.8rem);
  --case-metrics-value-size: clamp(1.875rem, 4.25vw, 2.75rem);
  --case-metrics-text-value-size: clamp(1.375rem, 3.25vw, 2rem);
  --case-intro-col-gap: clamp(3rem, 5vw, 5.5rem);
  --page-pad-top: calc(var(--nav-top-height) + 0.25rem);
  --page-pad-bottom: calc(var(--pin-pad) + 3rem);
  --page-block-gap: clamp(3.5rem, 7vh, 4.5rem);
  --content-max: 66.7%;
  --content-max-tablet: min(92%, 42rem);
  --hero-copy-max: min(20em, 90vw);
  --hero-copy-size: clamp(2.125rem, 4.5vw, 3.375rem);
  --hero-copy-lh: var(--type-display-lh);
  --space-section-y: clamp(1.5rem, 3vh, 2.25rem);
  --space-stack-sm: clamp(0.5rem, 1vh, 0.75rem);
  --space-stack-md: clamp(0.85rem, 1.6vh, 1.15rem);
}

* { box-sizing: border-box; }
html {
  font-size: var(--base-size);
  touch-action: manipulation;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--nav-top-height) + 0.5rem);
}
html.lenis,
html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-stopped { overflow: hidden; }

::selection {
  background-color: var(--selection-bg);
  color: var(--selection-ink);
}

::-moz-selection {
  background-color: var(--selection-bg);
  color: var(--selection-ink);
}

body {
  margin: 0;
  min-height: var(--viewport-height);
  background: #fff;
  color: var(--case-ink);
  font-family: var(--font-sans);
  font-size: var(--case-body-size);
  font-weight: var(--type-body-weight);
  line-height: var(--case-body-lh);
  letter-spacing: var(--case-body-track);
  -webkit-font-smoothing: antialiased;
  display: flex;
  flex-direction: column;
  isolation: isolate;
  opacity: 1;
  visibility: visible;
}

html.site-ready #loading-screen,
html.site-ready .loading-screen {
  display: none !important;
}

html.site-ready main,
html.site-ready .pages,
html.site-ready .case-page,
html.site-ready .case-shell,
html.site-ready .case-doc,
html.site-ready .case-callout,
html.site-ready .case-metrics,
html.site-ready .case-hero-media,
html.site-ready .case-asset,
html.site-ready .case-intro,
html.site-ready .project-block,
html.site-ready .playground-item,
html.site-ready img,
html.site-ready video {
  opacity: 1 !important;
  visibility: visible !important;
}

b,
strong {
  font-weight: var(--type-label-weight);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  opacity: 0;
  background:
    radial-gradient(circle 16.2vmin at var(--hero-glow-x, 50%) var(--hero-glow-y, 50%), var(--hero-glow-blue), transparent 68%),
    radial-gradient(circle 21.1vmin at var(--hero-glow-x, 50%) var(--hero-glow-y, 50%), var(--hero-glow-green), transparent 72%),
    radial-gradient(circle 25.9vmin at var(--hero-glow-x, 50%) var(--hero-glow-y, 50%), var(--hero-glow-sky), transparent 76%);
  transition: opacity .45s ease;
  will-change: background;
}

body.cursor-glow--active::before { opacity: 1; }

.pages,
.case-page,
.about-page {
  position: relative;
  z-index: 1;
}
a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease, opacity 0.2s ease;
}

a:hover:not(.roll-link),
a:focus-visible:not(.roll-link),
button:hover,
button:focus-visible,
.about-touch-item a:hover,
.about-touch-item a:focus-visible,
.lightbox-control:hover,
.lightbox-control:focus-visible {
  color: var(--link-hover-pink);
}

.roll-link:hover,
.roll-link:focus-visible {
  color: var(--link-hover);
}

.about-bio__email,
.about-bio__email:hover,
.about-bio__email:focus-visible,
.about-bio__email:active {
  color: var(--about-link, #006FE8);
  background: none;
  box-decoration-break: unset;
  -webkit-box-decoration-break: unset;
  padding: 0;
  border-radius: 0;
  opacity: 1;
  text-decoration: none;
  transition: none;
}

.about-bio__email.roll-link {
  height: auto;
  overflow: visible;
  vertical-align: baseline;
}

.about-bio__email.roll-link .roll-text,
.about-bio__email.roll-link:hover .roll-text,
.about-bio__email.roll-link:focus-visible .roll-text {
  transform: none;
  transition: none;
}

a:active:not(.about-bio__email),
button:active {
  opacity: 0.7;
}
img, video { display: block; max-width: 100%; height: auto; }

.pin {
  position: fixed;
  left: 0;
  right: 0;
  z-index: 50;
  padding: var(--pin-pad);
  pointer-events: none;
  font-size: var(--type-ui-size);
  font-weight: var(--type-ui-weight);
  letter-spacing: var(--case-body-track);
}
.pin > * { pointer-events: auto; }
.pin--top {
  top: 0;
  padding-top: max(var(--pin-pad), env(safe-area-inset-top, 0px));
}
.pin--bottom { bottom: 0; }

.bar {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  width: 100%;
}
.bar__right { text-align: right; }
.bar__nav-actions {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 1.25rem;
}
.nav-link--playground-mobile,
.nav-link--about-mobile {
  display: none;
}

.bar__left { text-align: left; }
.brand-mark { display: inline-block; }

.pin--middle .bar {
  grid-template-columns: 1fr 1fr;
  align-items: center;
}

.pin--middle .bar > .bar__left,
.pin--middle .bar > div:first-child {
  justify-self: start;
  text-align: left;
}

.pin--middle .bar > .bar__right {
  justify-self: end;
  text-align: right;
  width: 100%;
}

#day-clock,
#time-clock {
  font-variant-numeric: tabular-nums;
}

#time-clock {
  display: inline-block;
  min-width: 7.25ch;
  text-align: right;
}

.pin--middle {
  top: 0;
  bottom: 0;
  display: flex;
  align-items: center;
  padding-top: calc(var(--pin-pad) + 2.2rem);
  padding-bottom: calc(var(--pin-pad) + 2.4rem);
}
.pin--middle .bar { align-items: center; }

.pin--project-nav .project-nav-arrow {
  font-size: 1.35rem;
  font-weight: 400;
  letter-spacing: var(--case-serif-head-track);
  line-height: 1;
}

.pin--bottom .bar {
  grid-template-columns: 1fr 1fr;
  align-items: center;
}

.pages {
  flex: 1;
  width: 100%;
  padding-top: var(--page-pad-top);
  padding-bottom: var(--page-pad-bottom);
}

.section {
  width: 100%;
  display: flex;
  justify-content: center;
  padding: 0 var(--pin-pad);
}

.page-layout {
  width: 100%;
  max-width: var(--content-max);
}
.page-layout--full { max-width: 100%; }
.page-layout--center { text-align: center; }

.section--hero {
  min-height: calc(var(--viewport-height) - 7rem);
  align-items: center;
  justify-content: center;
  padding-top: calc(var(--pin-pad) + 2rem);
  padding-bottom: calc(var(--pin-pad) + 2rem);
}

.hero-intro {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: calc(var(--viewport-height) - 10rem);
}

.section--hero .hero-copy {
  line-height: var(--hero-copy-lh);
}

.hero-copy {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: var(--hero-copy-max);
  margin: 0 auto;
  display: block;
  text-align: center;
  font-family: var(--font-serif);
  font-size: var(--hero-copy-size);
  line-height: var(--hero-copy-lh);
  font-weight: var(--type-display-weight);
  letter-spacing: var(--type-display-track);
  font-feature-settings: "liga" 1, "kern" 1;
  text-transform: none;
  color: var(--case-ink);
}

.hero-line {
  display: block;
  width: 100%;
  max-width: none;
  margin: 0;
  text-align: center;
}

.hero-text {
  display: inline;
  text-wrap: pretty;
  color: var(--case-ink);
  transition: color 0.2s ease;
}

.hero-line:hover .hero-text,
.hero-line:focus-within .hero-text {
  color: var(--link-hover-pink);
}

.hero-scroll {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: clamp(2rem, 5vh, 3.25rem);
  color: var(--case-muted);
  opacity: 0;
  transition: color 0.2s ease;
}

.hero-scroll,
.hero-scroll:hover,
.hero-scroll:focus-visible,
.hero-scroll:active {
  background: none;
  box-decoration-break: unset;
  -webkit-box-decoration-break: unset;
  padding: 0;
  border-radius: 0;
}

.hero-scroll:hover,
.hero-scroll:focus-visible {
  color: var(--link-hover-pink);
  opacity: 1;
}

.hero-scroll__icon {
  display: block;
}

.hero-text--animate {
  display: inline-block;
}

.prose-copy {
  line-height: var(--case-body-lh);
  letter-spacing: var(--case-body-track);
  text-wrap: pretty;
}

.prose-copy p + p {
  margin-top: var(--prose-gap);
}

.project-block {
  margin-bottom: var(--page-block-gap);
  position: relative;
}
.project-hero { display: block; width: 100%; }
.project-hero img,
.project-hero video { width: 100%; }

.project-meta {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-stack-md);
  width: 100%;
  margin-top: var(--space-stack-md);
  align-items: start;
  font-size: var(--case-body-size);
  line-height: var(--case-body-lh);
  letter-spacing: var(--case-body-track);
}

.project-meta__left {
  justify-self: start;
  text-align: left;
  min-width: 0;
  width: 100%;
}

.project-meta__heading {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.5rem 1.5rem;
  width: 100%;
}

.project-meta__year {
  flex-shrink: 0;
  font-size: var(--case-body-size);
  font-weight: var(--type-ui-weight);
  line-height: var(--case-body-lh);
  letter-spacing: var(--case-body-track);
  color: var(--case-muted);
  text-wrap: nowrap;
}

.project-meta__left > a,
.project-meta__heading > a {
  display: inline-block;
  font-size: var(--type-emphasis-size);
  font-weight: var(--type-emphasis-weight);
  letter-spacing: var(--case-body-track);
}

.project-meta__right {
  justify-self: end;
  text-align: left;
  min-width: 0;
}

.project-meta__medium {
  margin: 0;
  max-width: 42ch;
  color: var(--case-ink);
  line-height: var(--case-body-lh);
  text-wrap: pretty;
}

.muted { color: var(--case-muted); }

.case-skills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0;
  max-width: none;
}

.case-skill {
  display: inline-flex;
  align-items: center;
  padding: 6px 11px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-family: var(--font-sans);
  font-size: 11px;
  font-weight: var(--type-body-weight);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--case-ink);
  line-height: 1.2;
  white-space: nowrap;
}

.content-divider {
  margin: 0;
  border: 0;
  border-top: 1px solid var(--rule-color);
  width: 100%;
}

.ext-icon::after {
  content: "\2197";
  font-size: 0.85em;
  margin-left: 0.15em;
}

@media (prefers-reduced-motion: reduce) {
  body::before { display: none; }
}

@media (max-width: 1024px) {
  :root {
    --viewport-height: 100dvh;
    --pin-pad: 1rem;
    --case-title-size: clamp(1.5rem, 4.5vw, 2rem);
    --case-callout-head-size: clamp(1.3125rem, 4.2vw, 1.625rem);
    --case-callout-subhead-size: clamp(1rem, 3vw, 1.125rem);
    --case-callout-head-gap: clamp(1rem, 2vh, 1.35rem);
    --case-callout-intro-gap: clamp(1rem, 2vh, 1.35rem);
    --case-callout-item-gap: clamp(0.5rem, 1vh, 0.7rem);
    --case-meta-label-size: var(--case-body-size);
    --case-meta-value-size: var(--case-body-size);
    --type-display-size: clamp(1.625rem, 4.8vw, 2.25rem);
    --nav-top-height: calc(var(--pin-pad) * 2 + var(--pin-bar-height) + 1px + env(safe-area-inset-top, 0px));
    --nav-bottom-height: calc(var(--pin-pad) * 2 + var(--pin-bar-height) + 1px + env(safe-area-inset-bottom, 0px));
    --page-pad-top: calc(var(--nav-top-height) + 0.35rem);
    --page-pad-bottom: calc(var(--pin-pad) + 2.5rem + env(safe-area-inset-bottom, 0px));
    --page-block-gap: clamp(2.5rem, 5vh, 3.25rem);
    --content-max: 100%;
    --case-callout-structure-gap: clamp(1rem, 2vh, 1.35rem);
    --case-callout-rule-pad: clamp(10px, 1.5vh, 14px);
    --case-prose-max: min(100%, 36rem);
    --hero-copy-max: min(19em, 92vw);
    --hero-copy-size: clamp(1.875rem, 5.5vw, 2.75rem);
    --prose-gap: 0.7em;
    --space-section-y: clamp(1.25rem, 2.5vh, 2rem);
  }

  html {
    scroll-padding-top: var(--page-pad-top);
  }

  .section {
    padding-left: max(var(--pin-pad), env(safe-area-inset-left, 0px));
    padding-right: max(var(--pin-pad), env(safe-area-inset-right, 0px));
  }

  .page-layout {
    max-width: var(--content-max);
  }

  .pin--middle:not(.pin--project-nav) { display: none; }

  footer.pin--bottom { display: none; }

  .nav-link--playground-desktop { display: none; }
  .nav-link--playground-mobile,
  .nav-link--about-mobile { display: inline-block; }

  .pin--top {
    background: #fff;
  }

  .pin--top .bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
  }

  .pin--top .bar > div:first-child {
    flex: 0 1 auto;
    min-width: 0;
  }

  .pin--top .bar__right {
    flex: 0 0 auto;
    margin-left: auto;
    text-align: right;
  }

  .bar__nav-actions {
    flex-direction: row-reverse;
    justify-content: flex-start;
    gap: 1rem;
  }

  .pin--project-nav.pin--middle {
    display: none;
  }

  .pages {
    padding-top: var(--page-pad-top);
    padding-bottom: var(--page-pad-bottom);
  }

  body:has(#project-nav-pin) .case-page {
    padding-top: var(--page-pad-top);
    padding-bottom: var(--page-pad-bottom);
  }

  .project-blurb {
    display: none;
  }

  .section--hero {
    min-height: calc(var(--viewport-height) - var(--nav-top-height) - 2rem);
    padding-top: clamp(1rem, 3vh, 1.75rem);
    padding-bottom: clamp(1rem, 3vh, 1.75rem);
  }

  .section--hero .hero-copy,
  .hero-copy {
    display: block;
    width: 100%;
    max-width: var(--hero-copy-max);
    margin-inline: auto;
    font-size: var(--hero-copy-size);
    line-height: var(--hero-copy-lh);
    letter-spacing: var(--type-display-track);
    text-wrap: pretty;
  }

  .section--hero .hero-line,
  .hero-line {
    display: block;
    width: 100%;
    max-width: none;
    margin: 0;
  }

  .hero-intro {
    min-height: calc(var(--viewport-height) - var(--nav-top-height) - 2rem);
    width: 100%;
  }

  .project-meta {
    grid-template-columns: 1fr;
    gap: var(--space-stack-sm);
    font-size: var(--case-body-size);
    line-height: var(--case-body-lh);
  }

  .project-meta__left,
  .project-meta__right {
    justify-self: stretch;
  }

  .project-meta__left > a,
  .project-meta__heading > a {
    font-size: var(--type-emphasis-size);
  }

  .project-meta__year {
    font-size: var(--case-body-size);
  }

  .project-meta__medium {
    max-width: none;
  }

  .project-block {
    margin-bottom: clamp(2.5rem, 5vh, 3.5rem);
  }

  #projects.section {
    padding-top: var(--space-section-y);
  }
}

.hero-lines--mobile {
  display: none;
}

.hero-lines--desktop .hero-line {
  display: block;
}

@media (min-width: 601px) {
  .hero-copy .hero-text {
    text-wrap: nowrap;
  }
}

@media (min-width: 601px) and (max-width: 1024px) {
  :root {
    --content-max: var(--content-max-tablet);
    --hero-copy-max: min(18em, 86vw);
    --page-block-gap: clamp(2.75rem, 5.5vh, 3.5rem);
    --case-intro-col-gap: clamp(2rem, 4vw, 3rem);
  }

  .page-layout:not(.page-layout--full) {
    margin-inline: auto;
  }

  .hero-intro {
    min-height: calc(var(--viewport-height) - var(--nav-top-height) - 3rem);
  }

  .project-block {
    margin-bottom: clamp(2.75rem, 6vh, 4rem);
  }
}

@media (max-width: 600px) {
  :root {
    --base-size: 16px;
    --pin-pad: 0.85rem;
    --case-title-size: clamp(1.4375rem, 6.5vw, 1.875rem);
    --case-callout-head-size: clamp(1.25rem, 5.5vw, 1.5rem);
    --case-callout-subhead-size: clamp(1rem, 3.8vw, 1.0625rem);
    --case-meta-label-size: var(--case-body-size);
    --hero-copy-size: clamp(1.625rem, 7vw, 2.375rem);
    --hero-copy-max: min(18em, 94vw);
    --page-pad-bottom: calc(var(--pin-pad) + 3rem + env(safe-area-inset-bottom, 0px));
    --page-block-gap: clamp(2rem, 4.5vh, 2.75rem);
    --space-section-y: clamp(1rem, 2vh, 1.5rem);
  }

  .pin {
    font-size: var(--type-ui-size);
    padding-left: max(var(--pin-pad), env(safe-area-inset-left, 0px));
    padding-right: max(var(--pin-pad), env(safe-area-inset-right, 0px));
  }

  .section--hero {
    min-height: auto;
    padding-top: clamp(0.75rem, 2vh, 1.25rem);
    padding-bottom: clamp(0.75rem, 2vh, 1.25rem);
  }

  .hero-intro {
    min-height: calc(var(--viewport-height) - var(--nav-top-height) - 1.5rem);
  }

  .section--hero .hero-copy,
  .hero-copy {
    font-size: var(--hero-copy-size);
    line-height: var(--hero-copy-lh);
  }

  .hero-lines--desktop {
    display: none;
  }

  .hero-lines--mobile {
    display: block;
  }

  .hero-lines--mobile .hero-line {
    display: block;
  }

  .hero-lines--mobile .hero-text,
  .hero-lines--mobile .hero-text--animate {
    display: inline;
    text-wrap: nowrap;
  }

  .project-meta__heading {
    gap: 0.5rem 1rem;
  }

  .project-block {
    margin-bottom: clamp(2.25rem, 4.5vh, 3.25rem);
  }
}
