@font-face {
  font-family: "Flaviotte.woff2";
  src: url("../assets/fonts/Flaviotte.woff2") format("woff2");
  font-weight: 900;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "GROZEN-MEDICAL-SemiBold-BF65d7e7a4c4005.woff2";
  src: url("../assets/fonts/GROZEN-MEDICAL-SemiBold-BF65d7e7a4c4005.woff2") format("woff2");
  font-weight: 900;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Minecraft.woff2";
  src: url("../assets/fonts/Minecraft.woff2") format("woff2");
  font-weight: 900;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "aalto-display-personal-use.woff2";
  src: url("../assets/fonts/aalto-display-personal-use.woff2") format("woff2");
  font-weight: 900;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Dirtyline 36Daysoftype 2022";
  src: url("../assets/fonts/dirtyline-36daysoftype-2022.woff2") format("woff2");
  font-weight: 900;
  font-style: normal;
  font-display: swap;
}

body[data-page="home"] {
  background: #fbfbfb;
  background-attachment: scroll;
  padding-bottom: 0;
}

body[data-page="home"]::before,
body[data-page="home"]::after {
  display: none;
}

.home-shell main {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.home-shell {
  --home-section-spacing: clamp(1.8rem, 4vw, 3.4rem);
  --home-meta-font-size: clamp(0.8rem, 0.92vw, 0.88rem);
}

.home-topline {
  padding: 1rem 1rem 1rem;
  background: #fbfbfb;
}

.home-topline > .container {
  width: 100%;
  max-width: none;
}

.home-topline-row {
  display: grid;
  grid-template-columns: auto auto auto auto auto;
  align-items: center;
  justify-content: space-between;
  gap: clamp(0.6rem, 1.3vw, 1.1rem);
  width: 100%;
}

.home-topline-text,
.home-topline-link {
  color: var(--color-text);
  font-size: var(--home-meta-font-size);
  line-height: 1;
  padding: 0;
  text-decoration: none;
  white-space: nowrap;
}

.home-topline-link {
  justify-self: center;
}

.home-topline-row > :first-child {
  justify-self: start;
}

.home-topline-row > :last-child {
  justify-self: end;
}

.home-topline-star {
  width: 0.95rem;
  height: 0.95rem;
  display: block;
  flex: 0 0 auto;
  transform-origin: 50% 50%;
}

.home-topline-star.is-spinning {
  animation: homeToplineStarSpin 900ms cubic-bezier(0.22, 1, 0.36, 1);
}

.home-footerline {
  margin-top: auto;
  padding: 1rem 1rem 1rem;
  background: #fbfbfb;
}

.home-footerline > .container {
  width: 100%;
  max-width: none;
}

.home-footerline-row {
  display: grid;
  grid-template-columns: auto auto auto auto auto auto auto;
  align-items: center;
  justify-content: space-between;
  gap: clamp(0.6rem, 1.3vw, 1.1rem);
  width: 100%;
}

.home-footerline-text,
.home-footerline-link {
  color: var(--color-text);
  font-size: var(--home-meta-font-size);
  line-height: 1;
  text-decoration: none;
  white-space: nowrap;
}

.home-footerline-row > :first-child {
  justify-self: start;
}

.home-footerline-row > :nth-child(2) {
  justify-self: center;
}

.home-footerline-row > :nth-child(3) {
  justify-self: end;
}

.home-footerline-row > :last-child {
  justify-self: end;
}

@keyframes homeToplineStarSpin {
  from {
    transform: rotate(0deg);
  }

  to {
    transform: rotate(360deg);
  }
}

.home-hero {
  padding: var(--home-section-spacing) 0;
  background: #fbfbfb;

}

.portfolio-particle-hero {
  position: relative;
  min-height: clamp(240px, 34vh, 420px);
  display: grid;
  place-items: center;
  overflow: hidden;
  isolation: isolate;
  background: #fbfbfb;
}

@media (min-width: 1440px) {
  .portfolio-particle-hero {
    min-height: clamp(340px, 48vh, 600px);
  }
}

@media (max-width: 720px) {
  .home-topline {
    padding: 1rem;
  }

  .home-topline-row {
    grid-template-columns: auto auto auto auto auto;
    justify-content: space-between;
    gap: 0.4rem;
  }

  .home-topline-text,
  .home-topline-link {
    font-size: 0.72rem;
    padding: 0;
  }

  .home-topline-star {
    width: 0.72rem;
    height: 0.72rem;
  }

  .home-topline-row > :first-child,
  .home-topline-row > :last-child {
    justify-self: start;
  }

  .home-topline-row > :last-child {
    justify-self: end;
  }

  .home-footerline {
    padding: 1rem;
  }

  .home-footerline-row {
    grid-template-columns: 1fr auto 1fr;
    justify-content: space-between;
    gap: 0.4rem;
  }

  .home-footerline-row > :nth-child(n + 4) {
    display: none;
  }

  .home-footerline-text,
  .home-footerline-link {
    font-size: 0.72rem;
  }

  .home-footerline-row > :first-child,
  .home-footerline-row > :nth-child(3),
  .home-footerline-star {
    justify-self: start;
  }

  .home-footerline-row > :nth-child(2) {
    justify-self: center;
  }

  .home-footerline-row > :nth-child(3) {
    justify-self: end;
  }

  .home-projects-index > .container {
    width: 100%;
  }
}

.portfolio-particle-hero canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  opacity: 0;
  transition: opacity 260ms ease;
}

.portfolio-particle-hero.is-particles-ready canvas {
  opacity: 1;
}

.portfolio-title-fallback {
  position: relative;
  z-index: 1;
  margin: 0;
  width: min(calc(100vw - 4rem), var(--container-width));
  max-width: min(calc(100vw - 4rem), var(--container-width));
  color: #050505;
  font-family: "Neue Haas Grotesk Text Family", Arial, sans-serif;
  font-size: clamp(4.7rem, 12.8vw, 10.2rem);
  font-weight: 900;
  line-height: 0.86;
  letter-spacing: 0;
  text-align: center;
  pointer-events: none;
  transition: opacity 180ms ease;
}

.portfolio-particle-hero.is-particles-ready .portfolio-title-fallback {
  opacity: 0;
}

.home-projects-index {
  --projects-index-media-width: clamp(18rem, 23vw, 25.5rem);
  --projects-index-gap: clamp(1rem, 2vw, 2.5rem);
  --projects-index-font-size: var(--home-meta-font-size);
  --projects-index-row-columns: repeat(4, minmax(0, 1fr));
  --projects-index-detail-columns:
    var(--projects-index-media-width)
    minmax(16rem, 1.2fr)
    minmax(12rem, 0.95fr)
    auto;
  padding: 1rem 1rem 1rem;
  background: #fbfbfb;
}

.home-projects-index > .container {
  width: 100%;
  max-width: none;
}

.home-projects-index-title {
  margin: 0 0 0.85rem;
  color: var(--color-text);
  font-size: var(--home-meta-font-size);
  font-weight: 700;
  line-height: 1;
}

.home-projects-index-heading {
  display: grid;
  grid-template-columns: var(--projects-index-row-columns);
  align-items: center;
  gap: var(--projects-index-gap);
  margin: 0 0 0.85rem;
}

.home-projects-index-heading .home-projects-index-title {
  margin: 0;
}

.home-projects-index-browse {
  grid-column: 2;
  margin: 0;
  color: var(--color-text);
  font-size: var(--home-meta-font-size);
  font-weight: 700;
  line-height: 1;
  text-align: left;
}

.home-projects-index-list {
  display: grid;
  gap: 0.24rem;
}

.home-projects-index-item {
  display: grid;
  gap: 0;
}

.home-projects-index-list:has(.home-projects-index-item.is-open) .home-projects-index-item:not(.is-open) .home-projects-index-row {
  color: #b7b7b7;
}

.home-projects-index-row {
  display: grid;
  grid-template-columns: var(--projects-index-row-columns);
  align-items: center;
  gap: var(--projects-index-gap);
  color: var(--color-text);
  font-size: var(--projects-index-font-size);
  font-weight: 400;
  line-height: 1.12;
  text-decoration: none;
  position: relative;
}

.home-projects-index-name {
  font-weight: 400;
  white-space: nowrap;
}

.home-projects-index-number {
  white-space: nowrap;
}

.home-projects-index-detail {
  display: grid;
  grid-template-rows: 0fr;
  opacity: 0;
  transition: grid-template-rows 320ms cubic-bezier(0.22, 1, 0.36, 1), opacity 180ms ease;
}

.home-projects-index-detail-inner {
  min-height: 0;
  overflow: hidden;
}

.home-projects-index-detail-content {
  display: grid;
  grid-template-columns: var(--projects-index-detail-columns);
  gap: var(--projects-index-gap);
  align-items: flex-start;
  padding: 0.35rem 0 0.95rem;
  color: inherit;
  text-decoration: none;
}

.home-projects-index-detail-image {
  grid-column: 1;
  width: 100%;
  height: auto;
  display: block;
  object-fit: contain;
  background: none;
  border-radius: 0;
  transform: translateY(0.6rem);
  opacity: 0;
  transition: transform 320ms cubic-bezier(0.22, 1, 0.36, 1), opacity 200ms ease;
}

.home-projects-index-detail-copy {
  grid-column: 2;
  align-self: start;
  max-width: min(24rem, 100%);
  margin: 0;
  color: rgb(130, 130, 130);
  font-size: var(--projects-index-font-size);
  line-height: 1.24;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 4;
  overflow: hidden;
  text-wrap: pretty;
  transform: translateY(0.6rem);
  opacity: 0;
  transition: transform 320ms cubic-bezier(0.22, 1, 0.36, 1), opacity 200ms ease;
}

.home-projects-index-year {
  text-align: right;
  transition: transform 180ms ease;
}

.home-projects-index-meta {
  grid-column: 4;
  justify-self: end;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  position: relative;
  padding-right: 1.25rem;
}

.home-projects-index-arrow {
  position: absolute;
  top: calc(50% - 0.02rem);
  right: 0;
  width: 0.95rem;
  height: 0.95rem;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 1;
  transform: translateY(-50%) translateX(0);
  transition: opacity 180ms ease, transform 180ms ease, filter 180ms ease;
  pointer-events: none;
}

.home-projects-index-arrow img {
  width: 100%;
  height: 100%;
  display: block;
}

.home-projects-index-list:has(.home-projects-index-item.is-open) .home-projects-index-item:not(.is-open) .home-projects-index-arrow img {
  filter: brightness(0) saturate(0%) opacity(0.28);
}

.home-projects-index-item.is-open .home-projects-index-detail,
.home-projects-index-item:focus-within .home-projects-index-detail {
  grid-template-rows: 1fr;
  opacity: 1;
}

.home-projects-index-item.is-open .home-projects-index-detail-image,
.home-projects-index-item:focus-within .home-projects-index-detail-image {
  transform: translateY(0);
  opacity: 1;
}

.home-projects-index-item.is-open .home-projects-index-detail-copy,
.home-projects-index-item:focus-within .home-projects-index-detail-copy {
  transform: translateY(0);
  opacity: 1;
}

.home-projects-index-row:hover .home-projects-index-year,
.home-projects-index-row:focus-visible .home-projects-index-year,
.home-projects-index-item.is-open .home-projects-index-year,
.home-projects-index-item:focus-within .home-projects-index-year {
  transform: translateX(-1.3rem);
}

.home-projects-index-row:hover .home-projects-index-arrow,
.home-projects-index-row:focus-visible .home-projects-index-arrow,
.home-projects-index-item.is-open .home-projects-index-arrow,
.home-projects-index-item:focus-within .home-projects-index-arrow {
  opacity: 1;
  transform: translateY(-50%) translateX(0);
}

.home-projects-index-row:hover .home-projects-index-arrow img,
.home-projects-index-row:focus-visible .home-projects-index-arrow img,
.home-projects-index-item.is-open .home-projects-index-arrow img,
.home-projects-index-item:focus-within .home-projects-index-arrow img {
  filter: none;
}

.home-projects-section,
.home-bottom {
  background: #fbfbfb;
}

.section-heading {
  max-width: none;
  margin-bottom: 1.05rem;
}

.home-projects-section .section-heading .eyebrow {
  color: var(--color-text);
  font-size: clamp(1.15rem, 1.5vw, 1.45rem);
  line-height: 1.05;
  letter-spacing: -0.04em;
  text-transform: none;
}

.mobile-project-cards {
  display: none;
}

.mobile-project-card {
  display: grid;
  gap: 1rem;
  padding: 1rem;
}

.mobile-project-card + .mobile-project-card {
  margin-top: 1rem;
}

.mobile-project-card img {
  border-radius: 20px;
}

.card-kicker {
  margin-bottom: 0.35rem;
  color: var(--color-muted);
  font-size: 0.8rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.home-bottom {
  padding-top: 0.5rem;
}

.bottom-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
}

.statement-card,
.contact-card {
  min-height: 280px;
  padding: 1.5rem;
}

.contact-card {
  background: linear-gradient(160deg, rgba(231, 239, 255, 0.94), rgba(255, 255, 255, 0.78));
}

.contact-links {
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
  margin-top: 1.25rem;
}

.contact-links a {
  color: var(--color-muted);
}

.contact-links a:hover {
  color: var(--color-text);
}

@media (max-width: 980px) {
  .bottom-grid,
  .projects-experience {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 849px) {
  .home-topline {
    padding: 1rem;
  }

  .home-topline-row {
    grid-template-columns: auto auto auto auto auto;
    justify-content: space-between;
    gap: 0.5rem;
  }

  .home-topline-row > :first-child,
  .home-topline-row > :last-child {
    justify-self: start;
  }

  .home-topline-row > :last-child {
    justify-self: end;
  }

  .home-topline-star {
    width: 0.78rem;
    height: 0.78rem;
  }

  .home-footerline {
    padding: 1rem;
  }

  .home-footerline-row {
    grid-template-columns: 1fr auto 1fr;
    justify-content: space-between;
    gap: 0.5rem;
  }

  .home-footerline-row > :nth-child(n + 4) {
    display: none;
  }

  .home-footerline-row > :first-child,
  .home-footerline-row > :nth-child(3),
  .home-footerline-star {
    justify-self: start;
  }

  .home-footerline-row > :nth-child(2) {
    justify-self: center;
  }

  .home-footerline-row > :nth-child(3) {
    justify-self: end;
  }

  .home-topline-text,
  .home-topline-link,
  .home-footerline-text,
  .home-footerline-link {
    font-size: 0.76rem;
  }

  .home-hero {
    min-height: clamp(260px, 40vh, 340px);
    padding: 0.45rem 0 0.75rem;
  }

  .portfolio-title-fallback {
    width: min(calc(100vw - 2.6rem), var(--container-width));
    max-width: min(calc(100vw - 2.6rem), var(--container-width));
    font-size: clamp(3.2rem, 12vw, 7rem);
    line-height: 0.9;
  }

  .home-projects-index {
    --projects-index-gap: 0.4rem;
    padding-top: 0.5rem;
  }

  .home-projects-index-heading {
    grid-template-columns: 1fr auto;
    gap: 0.4rem;
    margin: 0 0 0.45rem;
  }

  .home-projects-index-browse {
    grid-column: 2;
    justify-self: end;
  }

  .home-projects-index-row {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 0.2rem 0.75rem;
    padding: 0.65rem 0;
    border-top: 1px solid rgba(21, 21, 21, 0.08);
  }

  .home-projects-index-detail {
    display: grid;
  }

  .home-projects-index-meta {
    grid-column: 2;
    grid-row: 1 / span 2;
    align-self: center;
    padding-right: 0;
  }

  .home-projects-index-number,
  .home-projects-index-name,
  .home-projects-index-row > :nth-child(3) {
    white-space: nowrap;
  }

  .home-projects-index-row > :nth-child(3) {
    grid-column: 1;
    grid-row: 2;
  }

  .home-projects-index-number {
    display: none;
  }

  .home-projects-index-name::before {
    content: attr(data-project-number) " ";
  }

  .home-projects-index-year {
    text-align: left;
    justify-self: auto;
  }

  .home-projects-index-arrow {
    position: static;
    width: 0.85rem;
    height: 0.85rem;
    transform: none;
    opacity: 1;
  }

  .home-projects-index-row:hover .home-projects-index-year,
  .home-projects-index-row:focus-visible .home-projects-index-year,
  .home-projects-index-item.is-open .home-projects-index-year,
  .home-projects-index-item:focus-within .home-projects-index-year {
    transform: translateX(-0.35rem);
  }

  .home-projects-index-row:hover .home-projects-index-arrow,
  .home-projects-index-row:focus-visible .home-projects-index-arrow,
  .home-projects-index-item.is-open .home-projects-index-arrow,
  .home-projects-index-item:focus-within .home-projects-index-arrow {
    transform: none;
  }

  .home-projects-index-detail-content {
    grid-template-columns: var(--projects-index-media-width);
    justify-content: start;
  }

  .home-projects-index-detail-image {
    grid-column: 1;
    width: var(--projects-index-media-width);
  }

  .home-projects-index-detail-copy {
    display: none;
  }

  .projects-experience {
    display: none;
  }

  .mobile-project-cards {
    display: block;
  }

  .statement-card,
  .contact-card {
    min-height: auto;
  }
}

@media (max-width: 780px) {
  .home-hero {
    min-height: clamp(240px, 38vh, 320px);
  }

  .projects-experience {
    display: none;
  }

  .mobile-project-cards {
    display: block;
  }

  .statement-card,
  .contact-card {
    min-height: auto;
  }
}

@media (max-width: 720px) {
  .home-projects-index {
    --projects-index-gap: 0.4rem;
    padding-top: 0.45rem;
  }

  .home-hero {
    padding: 0.35rem 0 0.65rem;
  }

  .home-projects-index-heading {
    grid-template-columns: 1fr auto;
    gap: 0.4rem;
    margin: 0 0 0.4rem;
  }

  .home-projects-index-browse {
    justify-self: end;
  }

  .home-projects-index-row {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 0.2rem 0.75rem;
    padding: 0.65rem 0;
    border-top: 1px solid rgba(21, 21, 21, 0.08);
  }

  .home-projects-index-detail {
    display: grid;
  }

  .home-projects-index-meta {
    grid-column: 2;
    grid-row: 1 / span 2;
    align-self: center;
    padding-right: 0;
  }

  .home-projects-index-number,
  .home-projects-index-name,
  .home-projects-index-row > :nth-child(3) {
    white-space: nowrap;
  }

  .home-projects-index-row > :nth-child(3) {
    grid-column: 1;
    grid-row: 2;
  }

  .home-projects-index-number {
    display: none;
  }

  .home-projects-index-name::before {
    content: attr(data-project-number) " ";
  }

  .home-projects-index-year {
    text-align: left;
    justify-self: auto;
  }

  .home-projects-index-arrow {
    position: static;
    width: 0.85rem;
    height: 0.85rem;
    transform: none;
    opacity: 1;
  }

  .home-projects-index-row:hover .home-projects-index-year,
  .home-projects-index-row:focus-visible .home-projects-index-year,
  .home-projects-index-item.is-open .home-projects-index-year,
  .home-projects-index-item:focus-within .home-projects-index-year {
    transform: translateX(-0.35rem);
  }

  .home-projects-index-row:hover .home-projects-index-arrow,
  .home-projects-index-row:focus-visible .home-projects-index-arrow,
  .home-projects-index-item.is-open .home-projects-index-arrow,
  .home-projects-index-item:focus-within .home-projects-index-arrow {
    transform: none;
  }

  .home-projects-index-detail-content {
    grid-template-columns: var(--projects-index-media-width);
    justify-content: start;
  }

  .home-projects-index-detail-image {
    grid-column: 1;
    width: var(--projects-index-media-width);
  }

  .home-projects-index-detail-copy {
    display: none;
  }
}

:root[data-theme="contrast"] body[data-page="home"],
:root[data-theme="contrast"] .home-topline,
:root[data-theme="contrast"] .home-footerline,
:root[data-theme="contrast"] .home-hero,
:root[data-theme="contrast"] .portfolio-particle-hero,
:root[data-theme="contrast"] .home-projects-index,
:root[data-theme="contrast"] .home-projects-section,
:root[data-theme="contrast"] .home-bottom {
  background: #050505;
}

:root[data-theme="contrast"] .home-topline-star,
:root[data-theme="contrast"] .home-footerline-star {
  filter: brightness(0) invert(1);
}

:root[data-theme="contrast"] .portfolio-title-fallback {
  color: var(--theme-particle-color);
}

:root[data-theme="contrast"] .home-projects-index-list:has(.home-projects-index-item.is-open) .home-projects-index-item:not(.is-open) .home-projects-index-row {
  color: #5f5f5f;
}

:root[data-theme="contrast"] .home-projects-index-detail-copy {
  color: #9b9b9b;
}

:root[data-theme="contrast"] .home-projects-index-arrow img {
  filter: brightness(0) invert(1);
}

:root[data-theme="contrast"] .home-projects-index-list:has(.home-projects-index-item.is-open) .home-projects-index-item:not(.is-open) .home-projects-index-arrow img {
  filter: brightness(0) invert(1) opacity(0.32);
}

:root[data-theme="contrast"] .home-projects-index-row:hover .home-projects-index-arrow img,
:root[data-theme="contrast"] .home-projects-index-row:focus-visible .home-projects-index-arrow img,
:root[data-theme="contrast"] .home-projects-index-item.is-open .home-projects-index-arrow img,
:root[data-theme="contrast"] .home-projects-index-item:focus-within .home-projects-index-arrow img {
  filter: brightness(0) invert(1);
}

:root[data-theme="contrast"] .contact-card {
  background: linear-gradient(160deg, rgba(26, 26, 26, 0.98), rgba(8, 8, 8, 0.92));
}

@media (max-width: 849px) {
  :root[data-theme="contrast"] .home-projects-index-row {
    border-top-color: rgba(255, 255, 255, 0.12);
  }
}

@media (max-width: 720px) {
  :root[data-theme="contrast"] .home-projects-index-row {
    border-top-color: rgba(255, 255, 255, 0.12);
  }
}
