:root {
  color-scheme: light;
  --bg: #ffffff;
  --text: #111111;
  --muted: #666666;
  --line: #e7e7e7;
  --soft: #f7f7f7;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.45;
}

a {
  color: inherit;
  text-decoration-color: #c9c9c9;
  text-underline-offset: 3px;
}

a:hover {
  text-decoration-color: currentColor;
}

svg {
  display: block;
  fill: currentColor;
}

.page {
  width: min(1180px, calc(100vw - 32px));
  margin: 0 auto;
  padding: 40px 0 64px;
}

.header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 32px;
}

.header h1 {
  margin: 0;
  font-size: clamp(28px, 5vw, 56px);
  font-weight: 600;
  letter-spacing: 0;
}

.socials {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 14px;
  color: var(--muted);
  font-size: 14px;
}

.socials a,
.repo {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.socials svg,
.repo svg {
  width: 18px;
  height: 18px;
  flex: 0 0 auto;
}

.grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 28px 22px;
}

.project {
  min-width: 0;
}

.shot {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--soft);
}

.shot img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
}

.tweet {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  width: 100%;
  min-width: 0;
}

.twitter-tweet,
.twitter-tweet-rendered {
  width: 100% !important;
  max-width: none !important;
  margin: 0 !important;
}

.twitter-tweet iframe {
  width: 100% !important;
}

.project p {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 15px;
}

.project p a {
  color: var(--text);
}

.repo {
  margin-left: 4px;
  white-space: nowrap;
}

@media (max-width: 860px) {
  .header {
    display: block;
  }

  .socials {
    justify-content: flex-start;
    margin-top: 14px;
  }

  .grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 560px) {
  .page {
    width: min(100% - 24px, 1180px);
    padding-top: 28px;
  }

  .grid {
    grid-template-columns: 1fr;
    gap: 26px;
  }

  .project p {
    font-size: 14px;
  }
}
