:root {
  --color-ink: #040f16;
  --color-title-subtle: #696969;
  --color-text-muted: #4d4f52;
  --color-chip: #e9ecef;
  --color-background: #ffffff;
  --container-width: 1120px;
  --page-padding: 80px;
}

@font-face {
  font-family: "JetBrains Mono";
  src: url("fonts/jetbrains-mono-latin.woff2") format("woff2");
  font-style: normal;
  font-weight: 300 800;
  font-display: swap;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-width: 320px;
  background: var(--color-background);
  color: var(--color-ink);
  font-family: "JetBrains Mono", monospace;
}

img {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
}

p,
h1,
h2,
ul {
  margin: 0;
}

.container {
  width: min(var(--container-width), calc(100% - (var(--page-padding) * 2)));
  margin: 0 auto;
}

.site-header,
.site-footer {
  padding: 28px 0;
}

.site-header__row,
.site-footer__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
}

.site-header__brand,
.site-footer__text {
  font-size: 20px;
  line-height: 1.4;
  text-decoration: none;
}

.site-nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 24px;
}

.site-nav__link {
  font-size: 20px;
  line-height: 1.3;
  text-decoration: underline;
  text-underline-offset: 0.2em;
}

.intro {
  padding-top: 48px;
}

.intro__heading {
  display: grid;
  gap: 24px;
  max-width: 576px;
}

.intro__title {
  font-size: 40px;
  font-weight: 500;
  line-height: 1;
}

.intro__subtitle {
  color: var(--color-title-subtle);
  font-size: 32px;
  line-height: 1;
}

.intro__body {
  display: grid;
  gap: 44px;
  max-width: 834px;
  margin-top: 48px;
  font-size: 20px;
  line-height: 1.4;
}

.text-muted {
  color: var(--color-text-muted);
  font-weight: 300;
}

.text-link {
  font-weight: 800;
  text-decoration: underline;
  text-underline-offset: 0.18em;
}

.text-link--inline {
  font-weight: 400;
}

.projects {
  display: grid;
  gap: 120px;
  padding-top: 120px;
  padding-bottom: 80px;
}

.project-card {
  display: grid;
  grid-template-columns: minmax(300px, 405px) minmax(0, 691px);
  gap: 24px;
  align-items: start;
}

.project-card__content {
  display: grid;
  gap: 20px;
}

.project-card__title {
  font-size: 24px;
  font-weight: 800;
  line-height: 1;
}

.project-card__anchor {
  text-decoration: none;
}

.project-card__anchor:hover {
  text-decoration: underline;
  text-underline-offset: 0.18em;
}

.project-card__year {
  font-size: 20px;
  font-weight: 300;
  line-height: 1.4;
}

.chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 0;
  list-style: none;
}

.chip {
  padding: 8px;
  border-radius: 8px;
  background: var(--color-chip);
  color: var(--color-text-muted);
  font-size: 16px;
  font-weight: 500;
  line-height: 1.375;
}

.project-card__description {
  color: var(--color-text-muted);
  font-size: 20px;
  font-weight: 300;
  line-height: 1.4;
}

.project-card__media {
  margin: 0;
  aspect-ratio: 691 / 628;
}

.project-card__media picture {
  display: block;
}

.project-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

@media (max-width: 1100px) {
  :root {
    --page-padding: 32px;
  }

  .project-card {
    grid-template-columns: 1fr;
  }

  .project-card__content {
    max-width: 560px;
  }
}

@media (max-width: 760px) {
  :root {
    --page-padding: 20px;
  }

  .site-header,
  .site-footer {
    padding: 20px 0;
  }

  .site-header__row,
  .site-footer__row {
    align-items: flex-start;
    flex-direction: column;
    gap: 16px;
  }

  .site-footer__row {
    flex-direction: row;
    justify-content: space-between;
    gap: 12px;
  }

  .site-header__brand,
  .site-nav__link,
  .site-footer__text {
    font-size: 16px;
  }

  .site-nav {
    gap: 12px 16px;
    justify-content: flex-start;
  }

  .intro {
    padding-top: 28px;
  }

  .intro__title {
    font-size: 32px;
  }

  .intro__subtitle {
    font-size: 26px;
  }

  .intro__body,
  .project-card__description,
  .project-card__year {
    font-size: 16px;
    line-height: 1.6;
  }

  .intro__body {
    gap: 28px;
    margin-top: 40px;
  }

  .projects {
    gap: 72px;
    padding-top: 88px;
    padding-bottom: 56px;
  }

  .project-card__title {
    font-size: 22px;
  }

  .chip {
    font-size: 14px;
    line-height: 1.35;
  }
}
